diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:46:43 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:46:43 +0000 |
commit | ffe8a83e053396df448e9413828527613ca3bd46 (patch) | |
tree | a73d4169e02df4a50f9a12cb165fcd0ab5bac7c6 /kcmshell | |
parent | 682bf3bfdcbcbb1fca85e8a36ed03e062e0555d5 (diff) | |
download | tdelibs-ffe8a83e053396df448e9413828527613ca3bd46.tar.gz tdelibs-ffe8a83e053396df448e9413828527613ca3bd46.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1157647 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kcmshell')
-rw-r--r-- | kcmshell/main.cpp | 46 | ||||
-rw-r--r-- | kcmshell/main.h | 12 |
2 files changed, 29 insertions, 29 deletions
diff --git a/kcmshell/main.cpp b/kcmshell/main.cpp index e1b03d1e7..edd48f911 100644 --- a/kcmshell/main.cpp +++ b/kcmshell/main.cpp @@ -21,8 +21,8 @@ #include <iostream> -#include <qcstring.h> -#include <qfile.h> +#include <tqcstring.h> +#include <tqfile.h> #include <dcopclient.h> #include <qxembed.h> @@ -62,7 +62,7 @@ static KCmdLineOptions options[] = KCmdLineLastOption }; -static void listModules(const QString &baseGroup) +static void listModules(const TQString &baseGroup) { KServiceGroup::Ptr group = KServiceGroup::group(baseGroup); @@ -88,9 +88,9 @@ static void listModules(const QString &baseGroup) } } -static KService::Ptr locateModule(const QCString& module) +static KService::Ptr locateModule(const TQCString& module) { - QString path = QFile::decodeName(module); + TQString path = TQFile::decodeName(module); if (!path.endsWith(".desktop")) path += ".desktop"; @@ -126,12 +126,12 @@ bool KCMShell::isRunning() dcopClient()->attach(); // Reregister as anonymous dcopClient()->setNotifications(true); - QByteArray data; - QDataStream str( data, IO_WriteOnly ); + TQByteArray data; + TQDataStream str( data, IO_WriteOnly ); str << kapp->startupId(); - QCString replyType; - QByteArray replyData; - if (!dcopClient()->call(m_dcopName, "dialog", "activate(QCString)", + TQCString replyType; + TQByteArray replyData; + if (!dcopClient()->call(m_dcopName, "dialog", "activate(TQCString)", data, replyType, replyData)) { kdDebug(780) << "Calling DCOP function dialog::activate() failed." << endl; @@ -141,21 +141,21 @@ bool KCMShell::isRunning() return true; } -KCMShellMultiDialog::KCMShellMultiDialog( int dialogFace, const QString& caption, - QWidget *parent, const char *name, bool modal) +KCMShellMultiDialog::KCMShellMultiDialog( int dialogFace, const TQString& caption, + TQWidget *parent, const char *name, bool modal) : KCMultiDialog( dialogFace, caption, parent, name, modal ), DCOPObject("dialog") { } -void KCMShellMultiDialog::activate( QCString asn_id ) +void KCMShellMultiDialog::activate( TQCString asn_id ) { kdDebug(780) << k_funcinfo << endl; KStartupInfo::setNewStartupId( this, asn_id ); } -void KCMShell::setDCOPName(const QCString &dcopName, bool rootMode ) +void KCMShell::setDCOPName(const TQCString &dcopName, bool rootMode ) { m_dcopName = "kcmshell_"; if( rootMode ) @@ -170,12 +170,12 @@ void KCMShell::waitForExit() { kdDebug(780) << k_funcinfo << endl; - connect(dcopClient(), SIGNAL(applicationRemoved(const QCString&)), - SLOT( appExit(const QCString&) )); + connect(dcopClient(), TQT_SIGNAL(applicationRemoved(const TQCString&)), + TQT_SLOT( appExit(const TQCString&) )); exec(); } -void KCMShell::appExit(const QCString &appId) +void KCMShell::appExit(const TQCString &appId) { kdDebug(780) << k_funcinfo << endl; @@ -186,10 +186,10 @@ void KCMShell::appExit(const QCString &appId) } } -static void setIcon(QWidget *w, const QString &iconName) +static void setIcon(TQWidget *w, const TQString &iconName) { - QPixmap icon = DesktopIcon(iconName); - QPixmap miniIcon = SmallIcon(iconName); + TQPixmap icon = DesktopIcon(iconName); + TQPixmap miniIcon = SmallIcon(iconName); w->setIcon( icon ); //standard X11 #if defined Q_WS_X11 && ! defined K_WS_QTONLY KWin::setIcons(w->winId(), icon, miniIcon ); @@ -219,7 +219,7 @@ extern "C" KDE_EXPORT int kdemain(int _argc, char *_argv[]) const KCmdLineArgs *args = KCmdLineArgs::parsedArgs(); - const QCString lang = args->getOption("lang"); + const TQCString lang = args->getOption("lang"); if( !lang.isNull() ) KGlobal::locale()->setLanguage(lang); @@ -240,7 +240,7 @@ extern "C" KDE_EXPORT int kdemain(int _argc, char *_argv[]) for( KService::List::ConstIterator it = m_modules.begin(); it != m_modules.end(); ++it) { - QString entry("%1 - %2"); + TQString entry("%1 - %2"); entry = entry.arg((*it)->desktopEntryName().leftJustify(maxLen, ' ')) .arg(!(*it)->comment().isEmpty() ? (*it)->comment() @@ -257,7 +257,7 @@ extern "C" KDE_EXPORT int kdemain(int _argc, char *_argv[]) return -1; } - QCString dcopName; + TQCString dcopName; KService::List modules; for (int i = 0; i < args->count(); i++) { diff --git a/kcmshell/main.h b/kcmshell/main.h index 6b4c944ee..6a7c34ee7 100644 --- a/kcmshell/main.h +++ b/kcmshell/main.h @@ -43,7 +43,7 @@ public: * @param dcopName name to set the DCOP name to * @param rootMode true if the kcmshell is embedding */ - void setDCOPName(const QCString &dcopName, bool rootMode ); + void setDCOPName(const TQCString &dcopName, bool rootMode ); /** * Waits until the last instance of kcmshell with the same @@ -60,7 +60,7 @@ private slots: /** */ - void appExit( const QCString &appId ); + void appExit( const TQCString &appId ); private: @@ -68,7 +68,7 @@ private: * The DCOP name which actually is registered. * For example "kcmshell_mouse". */ - QCString m_dcopName; + TQCString m_dcopName; }; @@ -88,14 +88,14 @@ public: /** */ - KCMShellMultiDialog( int dialogFace, const QString& caption, - QWidget *parent=0, const char *name=0, bool modal=false); + KCMShellMultiDialog( int dialogFace, const TQString& caption, + TQWidget *parent=0, const char *name=0, bool modal=false); k_dcop: /** */ - virtual void activate( QCString asn_id ); + virtual void activate( TQCString asn_id ); }; |