Rename KStandard for enhanced compatibility with KDE4

pull/1/head
Timothy Pearson 12 years ago
parent 7f8c2db2f6
commit 4c89929629

@ -101,7 +101,7 @@ PropsDlgSharePlugin::PropsDlgSharePlugin( KPropertiesDialog *dlg,
void PropsDlgSharePlugin::slotConfigureFileSharing() void PropsDlgSharePlugin::slotConfigureFileSharing()
{ {
TDEProcess proc; TDEProcess proc;
proc << KStandardDirs::findExe("tdesu") << locate("exe", "tdecmshell") << "fileshare"; proc << TDEStandardDirs::findExe("tdesu") << locate("exe", "tdecmshell") << "fileshare";
proc.start( TDEProcess::DontCare ); proc.start( TDEProcess::DontCare );
} }

@ -82,8 +82,8 @@ KFileShareConfig::KFileShareConfig(TQWidget *parent, const char *name, const TQS
TQString path = TQString::fromLocal8Bit( getenv( "PATH" ) ); TQString path = TQString::fromLocal8Bit( getenv( "PATH" ) );
path += TQString::fromLatin1(":/usr/sbin"); path += TQString::fromLatin1(":/usr/sbin");
TQString sambaExec = KStandardDirs::findExe( TQString::fromLatin1("smbd"), path ); TQString sambaExec = TDEStandardDirs::findExe( TQString::fromLatin1("smbd"), path );
TQString nfsExec = KStandardDirs::findExe( TQString::fromLatin1("rpc.nfsd"), path ); TQString nfsExec = TDEStandardDirs::findExe( TQString::fromLatin1("rpc.nfsd"), path );
if ( nfsExec.isEmpty() && sambaExec.isEmpty()) if ( nfsExec.isEmpty() && sambaExec.isEmpty())
{ {

@ -504,7 +504,7 @@ void AppearanceConfig::slotLoadChatStyles()
void AppearanceConfig::updateEmoticonlist() void AppearanceConfig::updateEmoticonlist()
{ {
KopetePrefs *p = KopetePrefs::prefs(); KopetePrefs *p = KopetePrefs::prefs();
KStandardDirs dir; TDEStandardDirs dir;
d->mPrfsEmoticons->icon_theme_list->clear(); // Wipe out old list d->mPrfsEmoticons->icon_theme_list->clear(); // Wipe out old list
// Get a list of directories in our icon theme dir // Get a list of directories in our icon theme dir

@ -196,7 +196,7 @@ void EmoticonsEditDialog::slotEditClicked()
copy = false; copy = false;
TQString f = mMainWidget->klvEmoticons->selectedItem()->text(2); TQString f = mMainWidget->klvEmoticons->selectedItem()->text(2);
KStandardDirs *dir = TDEGlobal::dirs(); TDEStandardDirs *dir = TDEGlobal::dirs();
emo = dir->findResource( "emoticons", themeName + TQString::fromLatin1( "/" ) + f ); emo = dir->findResource( "emoticons", themeName + TQString::fromLatin1( "/" ) + f );
if( emo.isNull() ) if( emo.isNull() )

@ -296,7 +296,7 @@ Emoticons::~Emoticons( )
void Emoticons::addIfPossible( const TQString& filenameNoExt, const TQStringList &emoticons ) void Emoticons::addIfPossible( const TQString& filenameNoExt, const TQStringList &emoticons )
{ {
KStandardDirs *dir = TDEGlobal::dirs(); TDEStandardDirs *dir = TDEGlobal::dirs();
TQString pic; TQString pic;
//maybe an extension was given, so try to find the exact file //maybe an extension was given, so try to find the exact file

@ -55,7 +55,7 @@ LatexPlugin::LatexPlugin( TQObject *parent, const char *name, const TQStringList
connect( Kopete::ChatSessionManager::self(), TQT_SIGNAL( chatSessionCreated( Kopete::ChatSession * ) ), connect( Kopete::ChatSessionManager::self(), TQT_SIGNAL( chatSessionCreated( Kopete::ChatSession * ) ),
this, TQT_SLOT( slotNewChatSession( Kopete::ChatSession * ) ) ); this, TQT_SLOT( slotNewChatSession( Kopete::ChatSession * ) ) );
m_convScript = KStandardDirs::findExe("kopete_latexconvert.sh"); m_convScript = TDEStandardDirs::findExe("kopete_latexconvert.sh");
slotSettingsChanged(); slotSettingsChanged();
//Add GUI action to all already existing kmm (if the plugin is launched when kopete already rining) //Add GUI action to all already existing kmm (if the plugin is launched when kopete already rining)
@ -84,7 +84,7 @@ void LatexPlugin::slotNewChatSession( Kopete::ChatSession *KMM )
void LatexPlugin::slotMessageAboutToShow( Kopete::Message& msg ) void LatexPlugin::slotMessageAboutToShow( Kopete::Message& msg )
{ {
TQString mMagick = KStandardDirs::findExe("convert"); TQString mMagick = TDEStandardDirs::findExe("convert");
if ( mMagick.isEmpty() ) if ( mMagick.isEmpty() )
{ {
// show just once // show just once

@ -55,7 +55,7 @@ SMPPPDCSPrefs::SMPPPDCSPrefs(TQWidget* parent, const char* name, WFlags fl)
} }
// if netstat is NOT available, disable the option and set to SMPPPD // if netstat is NOT available, disable the option and set to SMPPPD
if(KStandardDirs::findExe("netstat") == TQString()) { if(TDEStandardDirs::findExe("netstat") == TQString()) {
autoCSTest->setEnabled(FALSE); autoCSTest->setEnabled(FALSE);
useNetstat->setEnabled(FALSE); useNetstat->setEnabled(FALSE);
useNetstat->setChecked(FALSE); useNetstat->setChecked(FALSE);

@ -52,7 +52,7 @@ WPEditAccount::WPEditAccount(TQWidget *parent, Kopete::Account *theAccount)
mProtocol = WPProtocol::protocol(); mProtocol = WPProtocol::protocol();
TQString tmpSmbcPath = KStandardDirs::findExe("smbclient"); TQString tmpSmbcPath = TDEStandardDirs::findExe("smbclient");
if(account()) { if(account()) {
mHostName->setText(account()->accountId()); mHostName->setText(account()->accountId());

@ -138,8 +138,8 @@ void WPProtocol::installSamba()
// kdDebug(14170) << "WPProtocol::installSamba()" endl; // kdDebug(14170) << "WPProtocol::installSamba()" endl;
TQStringList args; TQStringList args;
args += KStandardDirs::findExe("winpopup-install.sh"); args += TDEStandardDirs::findExe("winpopup-install.sh");
args += KStandardDirs::findExe("winpopup-send.sh"); args += TDEStandardDirs::findExe("winpopup-send.sh");
if (TDEApplication::tdeinitExecWait("tdesu", args) == 0) if (TDEApplication::tdeinitExecWait("tdesu", args) == 0)
KMessageBox::information(Kopete::UI::Global::mainWidget(), i18n("The Samba configuration file is modified."), i18n("Configuration Succeeded")); KMessageBox::information(Kopete::UI::Global::mainWidget(), i18n("The Samba configuration file is modified."), i18n("Configuration Succeeded"));
else else

@ -603,7 +603,7 @@ void YahooContact::inviteConference()
void YahooContact::inviteWebcam() void YahooContact::inviteWebcam()
{ {
if ( !KStandardDirs::findExe("jasper") ) if ( !TDEStandardDirs::findExe("jasper") )
{ {
KMessageBox::queuedMessageBox( Kopete::UI::Global::mainWidget(), KMessageBox::Error, KMessageBox::queuedMessageBox( Kopete::UI::Global::mainWidget(), KMessageBox::Error,
i18n("I cannot find the jasper image convert program.\njasper is required to render the yahoo webcam images." i18n("I cannot find the jasper image convert program.\njasper is required to render the yahoo webcam images."
@ -658,7 +658,7 @@ void YahooContact::initWebcamViewer()
void YahooContact::requestWebcam() void YahooContact::requestWebcam()
{ {
if ( !KStandardDirs::findExe("jasper") ) if ( !TDEStandardDirs::findExe("jasper") )
{ {
KMessageBox::queuedMessageBox( Kopete::UI::Global::mainWidget(), KMessageBox::Error, KMessageBox::queuedMessageBox( Kopete::UI::Global::mainWidget(), KMessageBox::Error,
i18n("I cannot find the jasper image convert program.\njasper is required to render the yahoo webcam images." i18n("I cannot find the jasper image convert program.\njasper is required to render the yahoo webcam images."

@ -271,7 +271,7 @@
* connect.cpp: skip setting the volume if command is empty * connect.cpp: skip setting the volume if command is empty
* switched from KWizard to QWizard * switched from KWizard to QWizard
* adaption to new TDEConfig iterators * adaption to new TDEConfig iterators
* partly switched to KStandardDirs * partly switched to TDEStandardDirs
1999-05-07 Harri Porten <porten@kde.org> 1999-05-07 Harri Porten <porten@kde.org>

@ -96,7 +96,7 @@ KVncView::KVncView(TQWidget *parent,
connect(m_cb, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(selectionChanged())); connect(m_cb, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(selectionChanged()));
connect(m_cb, TQT_SIGNAL(dataChanged()), this, TQT_SLOT(clipboardChanged())); connect(m_cb, TQT_SIGNAL(dataChanged()), this, TQT_SLOT(clipboardChanged()));
KStandardDirs *dirs = TDEGlobal::dirs(); TDEStandardDirs *dirs = TDEGlobal::dirs();
TQBitmap cursorBitmap(dirs->findResource("appdata", TQBitmap cursorBitmap(dirs->findResource("appdata",
"pics/pointcursor.png")); "pics/pointcursor.png"));
TQBitmap cursorMask(dirs->findResource("appdata", TQBitmap cursorMask(dirs->findResource("appdata",

@ -273,8 +273,8 @@ void KSoundPageConfig::soundOnOff()
void KSoundPageConfig::defaults() { void KSoundPageConfig::defaults() {
extprg_edit->lineEdit()->setText(KStandardDirs::findExe("ktalkdlg")); extprg_edit->lineEdit()->setText(TDEStandardDirs::findExe("ktalkdlg"));
client_edit->lineEdit()->setText(KStandardDirs::findExe("konsole")+" -e talk"); client_edit->lineEdit()->setText(TDEStandardDirs::findExe("konsole")+" -e talk");
// will be ktalk when ktalk is in CVS. // will be ktalk when ktalk is in CVS.
sound_cb->setChecked(true); sound_cb->setChecked(true);
@ -287,13 +287,13 @@ void KSoundPageConfig::load() {
config->setGroup("ktalkd"); config->setGroup("ktalkd");
announceconfig->setGroup("ktalkannounce"); announceconfig->setGroup("ktalkannounce");
setenv("TDEBINDIR",TQFile::encodeName(KStandardDirs::kde_default("exe")),false/*don't overwrite*/); setenv("TDEBINDIR",TQFile::encodeName(TDEStandardDirs::kde_default("exe")),false/*don't overwrite*/);
// for the first reading of the config file // for the first reading of the config file
extprg_edit->lineEdit()->setText(config->readPathEntry("ExtPrg", extprg_edit->lineEdit()->setText(config->readPathEntry("ExtPrg",
KStandardDirs::findExe("ktalkdlg"))); TDEStandardDirs::findExe("ktalkdlg")));
client_edit->lineEdit()->setText(announceconfig->readPathEntry("talkprg", client_edit->lineEdit()->setText(announceconfig->readPathEntry("talkprg",
KStandardDirs::findExe("konsole")+" -e talk")); // will be ktalk when ktalk is in CVS TDEStandardDirs::findExe("konsole")+" -e talk")); // will be ktalk when ktalk is in CVS
bool b = announceconfig->readBoolEntry("Sound",true/*default value*/); bool b = announceconfig->readBoolEntry("Sound",true/*default value*/);
sound_cb->setChecked(b); sound_cb->setChecked(b);

@ -249,7 +249,7 @@ int process_config_file(void)
tqstrncpy(Options.extprg,TQFile::encodeName(result),S_CFGLINE); tqstrncpy(Options.extprg,TQFile::encodeName(result),S_CFGLINE);
ktalk_debug("Ext prg = %s",Options.extprg); } ktalk_debug("Ext prg = %s",Options.extprg); }
else { /* has to work even without config file at all */ else { /* has to work even without config file at all */
KStandardDirs stddirs; TDEStandardDirs stddirs;
tqstrncpy(Options.extprg, TQFile::encodeName(stddirs.findResource("exe","ktalkdlg")), S_CFGLINE-1); tqstrncpy(Options.extprg, TQFile::encodeName(stddirs.findResource("exe","ktalkdlg")), S_CFGLINE-1);
} }

@ -531,9 +531,9 @@ TQTable* Interface_wireless_wirelessextensions::get_available_networks ()
networks->horizontalHeader()->setLabel( 3, i18n("WEP") ); networks->horizontalHeader()->setLabel( 3, i18n("WEP") );
KProcIO *iwlist = new KProcIO; KProcIO *iwlist = new KProcIO;
TQString iwlist_bin = KStandardDirs::findExe("iwlist"); TQString iwlist_bin = TDEStandardDirs::findExe("iwlist");
if(iwlist_bin.isEmpty()) if(iwlist_bin.isEmpty())
iwlist_bin = KStandardDirs::findExe("iwlist", "/usr/local/sbin:/usr/sbin:/sbin"); iwlist_bin = TDEStandardDirs::findExe("iwlist", "/usr/local/sbin:/usr/sbin:/sbin");
if(iwlist_bin.isEmpty()) if(iwlist_bin.isEmpty())
iwlist_bin = "iwlist"; // try our best ;/ iwlist_bin = "iwlist"; // try our best ;/

@ -142,7 +142,7 @@ KWiFiManagerApp::~KWiFiManagerApp ()
void void
KWiFiManagerApp::init_whois_db () KWiFiManagerApp::init_whois_db ()
{ {
KStandardDirs finder; TDEStandardDirs finder;
TQString tdedir = TQString tdedir =
finder.findResourceDir ("data", "kwifimanager/locations/NOWHERE.loc"); finder.findResourceDir ("data", "kwifimanager/locations/NOWHERE.loc");
tdedir += "kwifimanager/locations/"; tdedir += "kwifimanager/locations/";

@ -29,7 +29,7 @@ Picture::Picture (TQWidget * parent, Interface_wireless * device):TQWidget (pare
"picture") "picture")
{ {
this->device = device; this->device = device;
KStandardDirs finder; TDEStandardDirs finder;
tdedir = finder.findResourceDir ("data", "kwifimanager/pics/no_card.png"); tdedir = finder.findResourceDir ("data", "kwifimanager/pics/no_card.png");
tdedir += "kwifimanager/pics/"; tdedir += "kwifimanager/pics/";
NO_CARD = new TQPixmap (tdedir + "no_card.png"); NO_CARD = new TQPixmap (tdedir + "no_card.png");

@ -31,7 +31,7 @@ Strength::Strength (TQWidget * parent, Interface_wireless * device):TQWidget (pa
"strength") "strength")
{ {
this->device = device; this->device = device;
KStandardDirs finder; TDEStandardDirs finder;
tdedir = finder.findResourceDir ("data", "kwifimanager/pics/no_card.png"); tdedir = finder.findResourceDir ("data", "kwifimanager/pics/no_card.png");
tdedir += "kwifimanager/pics/"; tdedir += "kwifimanager/pics/";
NOT_CON_OFFLINE_ADHOC = new TQPixmap (tdedir + "offline.png"); NOT_CON_OFFLINE_ADHOC = new TQPixmap (tdedir + "offline.png");

Loading…
Cancel
Save