From 79b21d47bce1ee428affc97534cd8b257232a871 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 24 Jan 2013 13:43:14 -0600 Subject: Rename KGlobal, KProcess, and KClipboard to avoid conflicts with KDE4 --- kcontrol/samba/AUTHORS | 2 +- kcontrol/samba/kcmsambastatistics.cpp | 4 ++-- kcontrol/samba/ksmbstatus.cpp | 18 +++++++++--------- kcontrol/samba/ksmbstatus.h | 6 +++--- 4 files changed, 15 insertions(+), 15 deletions(-) (limited to 'kcontrol/samba') diff --git a/kcontrol/samba/AUTHORS b/kcontrol/samba/AUTHORS index 0bebeaa06..08f2ff61b 100644 --- a/kcontrol/samba/AUTHORS +++ b/kcontrol/samba/AUTHORS @@ -6,7 +6,7 @@ Conversion to kcontrol applet: Matthias Hoelzer -Use of KProcess instead of popen, and more error checking +Use of TDEProcess instead of popen, and more error checking David Faure diff --git a/kcontrol/samba/kcmsambastatistics.cpp b/kcontrol/samba/kcmsambastatistics.cpp index 431e0f51a..1e3fa2175 100644 --- a/kcontrol/samba/kcmsambastatistics.cpp +++ b/kcontrol/samba/kcmsambastatistics.cpp @@ -126,8 +126,8 @@ void StatisticsView::setListInfo(TQListView *list, int nrOfFiles, int nrOfConnec dataList=list; filesCount=nrOfFiles; connectionsCount=nrOfConnections; - connectionsL->setText(i18n("Connections: %1").arg(KGlobal::locale()->formatNumber(connectionsCount, 0))); - filesL->setText(i18n("File accesses: %1").arg(KGlobal::locale()->formatNumber(filesCount, 0))); + connectionsL->setText(i18n("Connections: %1").arg(TDEGlobal::locale()->formatNumber(connectionsCount, 0))); + filesL->setText(i18n("File accesses: %1").arg(TDEGlobal::locale()->formatNumber(filesCount, 0))); clearStatistics(); } diff --git a/kcontrol/samba/ksmbstatus.cpp b/kcontrol/samba/ksmbstatus.cpp index bf775deab..effd67312 100644 --- a/kcontrol/samba/ksmbstatus.cpp +++ b/kcontrol/samba/ksmbstatus.cpp @@ -130,7 +130,7 @@ void NetMon::processSambaLine(char *bufline, int) // called when we get some data from smbstatus // can be called for any size of buffer (one line, several lines, // half of one ...) -void NetMon::slotReceivedData(KProcess *, char *buffer, int ) +void NetMon::slotReceivedData(TDEProcess *, char *buffer, int ) { //kdDebug()<<"received stuff"<clear(); @@ -175,10 +175,10 @@ void NetMon::update() nrpid=0; process->setEnvironment("PATH", path); connect(process, - TQT_SIGNAL(receivedStdout(KProcess *, char *, int)), - TQT_SLOT(slotReceivedData(KProcess *, char *, int))); + TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)), + TQT_SLOT(slotReceivedData(TDEProcess *, char *, int))); *process << "smbstatus"; - if (!process->start(KProcess::Block,KProcess::Stdout)) + if (!process->start(TDEProcess::Block,TDEProcess::Stdout)) version->setText(i18n("Error: Unable to run smbstatus")); else if (rownumber==0) // empty result version->setText(i18n("Error: Unable to open configuration file \"smb.conf\"")); @@ -197,16 +197,16 @@ void NetMon::update() readingpart=nfs; delete showmountProc; - showmountProc=new KProcess(); + showmountProc=new TDEProcess(); showmountProc->setEnvironment("PATH", path); *showmountProc<<"showmount"<<"-a"<<"localhost"; - connect(showmountProc,TQT_SIGNAL(receivedStdout(KProcess *, char *, int)),TQT_SLOT(slotReceivedData(KProcess *, char *, int))); + connect(showmountProc,TQT_SIGNAL(receivedStdout(TDEProcess *, char *, int)),TQT_SLOT(slotReceivedData(TDEProcess *, char *, int))); //without this timer showmount hangs up to 5 minutes //if the portmapper daemon isn't running TQTimer::singleShot(5000,this,TQT_SLOT(killShowmount())); //kdDebug()<<"starting kill timer with 5 seconds"<start(KProcess::NotifyOnExit,KProcess::Stdout)) // run showmount + connect(showmountProc,TQT_SIGNAL(processExited(TDEProcess*)),this,TQT_SLOT(killShowmount())); + if (!showmountProc->start(TDEProcess::NotifyOnExit,TDEProcess::Stdout)) // run showmount { delete showmountProc; showmountProc=0; diff --git a/kcontrol/samba/ksmbstatus.h b/kcontrol/samba/ksmbstatus.h index a38eca897..e256de067 100644 --- a/kcontrol/samba/ksmbstatus.h +++ b/kcontrol/samba/ksmbstatus.h @@ -30,7 +30,7 @@ class TQListView; class TQListViewItem; -class KProcess; +class TDEProcess; class NetMon : public TQWidget { @@ -41,7 +41,7 @@ public: void loadSettings() {}; private: KConfig *configFile; - KProcess *showmountProc; + TDEProcess *showmountProc; TQListView *list; TQLabel *version; TQTimer *timer; @@ -59,7 +59,7 @@ private: private slots: void killShowmount(); void update(); - void slotReceivedData(KProcess *proc, char *buffer, int buflen); + void slotReceivedData(TDEProcess *proc, char *buffer, int buflen); }; #endif // main_included -- cgit v1.2.3