diff options
Diffstat (limited to 'kdelirc/irkick')
-rw-r--r-- | kdelirc/irkick/irkick.cpp | 16 | ||||
-rw-r--r-- | kdelirc/irkick/irkick.h | 3 | ||||
-rw-r--r-- | kdelirc/irkick/klircclient.cpp | 8 | ||||
-rw-r--r-- | kdelirc/irkick/klircclient.h | 5 |
4 files changed, 17 insertions, 15 deletions
diff --git a/kdelirc/irkick/irkick.cpp b/kdelirc/irkick/irkick.cpp index fdcfa3a..036974c 100644 --- a/kdelirc/irkick/irkick.cpp +++ b/kdelirc/irkick/irkick.cpp @@ -44,10 +44,10 @@ void IRKTrayIcon::mousePressEvent(TQMouseEvent *e) { - KSystemTray::mousePressEvent(new TQMouseEvent(TQEvent::MouseButtonPress, e->pos(), e->globalPos(), e->button() == LeftButton ? RightButton : e->button(), e->state())); + KSystemTray::mousePressEvent(new TQMouseEvent(TQEvent::MouseButtonPress, e->pos(), e->globalPos(), e->button() == Qt::LeftButton ? Qt::RightButton : e->button(), e->state())); } -IRKick::IRKick(const TQCString &obj) : TQObject(), DCOPObject(obj), npApp(TQString::null) +IRKick::IRKick(const TQCString &obj) : TQObject(), DCOPObject(obj), npApp(TQString()) { kapp->dcopClient()->setDefaultObject(obj); theClient = new KLircClient(); @@ -195,7 +195,7 @@ bool IRKick::getPrograms(const IRAction &action, TQStringList &programs) for(QCStringList::iterator i = buf.begin(); i != buf.end(); ++i) { TQString program = TQString::fromUtf8(*i); - if(program.contains(r)) + if(program.tqcontains(r)) programs += program; } if(programs.size() > 1 && action.ifMulti() == IM_DONTSEND) @@ -206,7 +206,7 @@ bool IRKick::getPrograms(const IRAction &action, TQStringList &programs) for(TQValueList<WId>::iterator i = s.fromLast(); i != s.end(); i--) { int p = KWin::info(*i).pid; TQString id = action.program() + "-" + TQString().setNum(p); - if(programs.contains(id)) + if(programs.tqcontains(id)) { programs.clear(); programs += id; break; @@ -220,7 +220,7 @@ bool IRKick::getPrograms(const IRAction &action, TQStringList &programs) for(TQValueList<WId>::iterator i = s.begin(); i != s.end(); ++i) { int p = KWin::info(*i).pid; TQString id = action.program() + "-" + TQString().setNum(p); - if(programs.contains(id)) + if(programs.tqcontains(id)) { programs.clear(); programs += id; break; @@ -244,7 +244,7 @@ void IRKick::executeAction(const IRAction &action) { TQString sname = ProfileServer::profileServer()->getServiceName(action.program()); if(!sname.isNull()) { - KPassivePopup::message("IRKick", i18n("Starting <b>%1</b>...").arg(action.application()), SmallIcon("irkick"), theTrayIcon); + KPassivePopup::message("IRKick", i18n("Starting <b>%1</b>...").tqarg(action.application()), SmallIcon("irkick"), theTrayIcon); KApplication::startServiceByDesktopName(sname); } } @@ -282,7 +282,7 @@ void IRKick::gotMessage(const TQString &theRemote, const TQString &theButton, in if(!npApp.isNull()) { TQString theApp = npApp; - npApp = TQString::null; + npApp = TQString(); // send notifier by DCOP to npApp/npModule/npMethod(theRemote, theButton); TQByteArray data; TQDataStream arg(data, IO_WriteOnly); arg << theRemote << theButton; @@ -330,7 +330,7 @@ void IRKick::stealNextPress(TQString app, TQString module, TQString method) void IRKick::dontStealNextPress() { - npApp = TQString::null; + npApp = TQString(); } #include "irkick.moc" diff --git a/kdelirc/irkick/irkick.h b/kdelirc/irkick/irkick.h index 92c2d9c..d55dcee 100644 --- a/kdelirc/irkick/irkick.h +++ b/kdelirc/irkick/irkick.h @@ -36,12 +36,13 @@ public: KPopupMenu* contextMenu() const { return KSystemTray::contextMenu(); } KActionCollection* actionCollection() { return KSystemTray::actionCollection(); } - IRKTrayIcon(TQWidget *parent = 0, const char *name = 0): KSystemTray(parent, name) {} + IRKTrayIcon(TQWidget *tqparent = 0, const char *name = 0): KSystemTray(tqparent, name) {} }; class IRKick: public TQObject, public DCOPObject { Q_OBJECT +// TQ_OBJECT K_DCOP TQString npApp, npModule, npMethod; diff --git a/kdelirc/irkick/klircclient.cpp b/kdelirc/irkick/klircclient.cpp index 3ce33d6..544eb2a 100644 --- a/kdelirc/irkick/klircclient.cpp +++ b/kdelirc/irkick/klircclient.cpp @@ -43,7 +43,7 @@ #include "klircclient.h" -KLircClient::KLircClient(TQWidget *parent, const char *name) : TQObject(parent, name), theSocket(0), listIsUpToDate(false) +KLircClient::KLircClient(TQWidget *tqparent, const char *name) : TQObject(tqparent, name), theSocket(0), listIsUpToDate(false) { connectToLirc(); } @@ -177,14 +177,14 @@ void KLircClient::slotRead() { // <code> <repeat> <button name> <remote control name> line.remove(0, 17); // strip code - int pos = line.find(' '); + int pos = line.tqfind(' '); if (pos < 0) return; bool ok; int repeat = line.left(pos).toInt(&ok, 16); if (!ok) return; line.remove(0, pos + 1); - pos = line.find(' '); + pos = line.tqfind(' '); if (pos < 0) return; TQString btn = line.left(pos); if(btn.startsWith("'") && btn.endsWith("'")) @@ -223,7 +223,7 @@ const TQString KLircClient::readLine() theSocket->waitForMore(500, &timeout); if (timeout) { // something's wrong. there ain't no line comin! - return TQString::null; + return TQString(); } } TQString line = theSocket->readLine(); diff --git a/kdelirc/irkick/klircclient.h b/kdelirc/irkick/klircclient.h index e271b23..24089c8 100644 --- a/kdelirc/irkick/klircclient.h +++ b/kdelirc/irkick/klircclient.h @@ -26,9 +26,10 @@ class TQSocketNotifier; @author Gav Wood */ -class KLircClient: public QObject +class KLircClient: public TQObject { Q_OBJECT + TQ_OBJECT private: struct lirc_config *theConfig; @@ -107,7 +108,7 @@ public: */ bool connectToLirc(); - KLircClient(TQWidget *parent = 0, const char *name = 0); + KLircClient(TQWidget *tqparent = 0, const char *name = 0); ~KLircClient(); }; |