From 47c8a359c5276062c4bc17f0e82410f29081b502 Mon Sep 17 00:00:00 2001 From: tpearson Date: Sat, 31 Jul 2010 19:48:06 +0000 Subject: Trinity Qt initial conversion git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- ksirc/puke/commands.h | 10 +++---- ksirc/puke/controller.cpp | 60 ++++++++++++++++++++--------------------- ksirc/puke/controller.h | 46 +++++++++++++++---------------- ksirc/puke/palistbox.cpp | 4 +-- ksirc/puke/palistbox.h | 2 +- ksirc/puke/pbutton.cpp | 34 +++++++++++------------ ksirc/puke/pbutton.h | 8 +++--- ksirc/puke/pframe.cpp | 16 +++++------ ksirc/puke/pframe.h | 8 +++--- ksirc/puke/pkfiledialog.cpp | 6 ++--- ksirc/puke/pkfiledialog.h | 2 +- ksirc/puke/plabel.cpp | 24 ++++++++--------- ksirc/puke/plabel.h | 8 +++--- ksirc/puke/playout.cpp | 18 ++++++------- ksirc/puke/playout.h | 12 ++++----- ksirc/puke/plined.cpp | 24 ++++++++--------- ksirc/puke/plined.h | 8 +++--- ksirc/puke/plistbox.cpp | 32 +++++++++++----------- ksirc/puke/plistbox.h | 8 +++--- ksirc/puke/pmenudta.cpp | 14 +++++----- ksirc/puke/pmenudta.h | 18 ++++++------- ksirc/puke/pmessage.h | 6 ++--- ksirc/puke/pobject.cpp | 26 +++++++++--------- ksirc/puke/pobject.h | 20 +++++++------- ksirc/puke/pobjfinder.cpp | 14 +++++----- ksirc/puke/pobjfinder.h | 4 +-- ksirc/puke/ppopmenu.cpp | 26 +++++++++--------- ksirc/puke/ppopmenu.h | 8 +++--- ksirc/puke/pprogress.cpp | 12 ++++----- ksirc/puke/pprogress.h | 2 +- ksirc/puke/ppushbt.cpp | 14 +++++----- ksirc/puke/ppushbt.h | 8 +++--- ksirc/puke/ptabdialog.cpp | 20 +++++++------- ksirc/puke/ptabdialog.h | 10 +++---- ksirc/puke/ptablevw.cpp | 8 +++--- ksirc/puke/ptablevw.h | 8 +++--- ksirc/puke/pwidget.cpp | 66 ++++++++++++++++++++++----------------------- ksirc/puke/pwidget.h | 34 +++++++++++------------ 38 files changed, 324 insertions(+), 324 deletions(-) (limited to 'ksirc/puke') diff --git a/ksirc/puke/commands.h b/ksirc/puke/commands.h index 3e45d8ba..50ff88b2 100644 --- a/ksirc/puke/commands.h +++ b/ksirc/puke/commands.h @@ -166,7 +166,7 @@ // cArg: not defined #define PUKE_WIDGET_RESIZE_ACK -1015 -// -1020 to -1040 defines QEvent types +// -1020 to -1040 defines TQEvent types // All arguments are 0 unless otherwise stated #define PUKE_WIDGET_EVENT_NONE -1020 // iArg: timerId @@ -347,7 +347,7 @@ // cArg: 0 #define PUKE_WIDGET_RECREATE_ACK -1091 -// QFrame gets 1100 +// TQFrame gets 1100 // 1100 defines QFrame // Desc: set Frame style @@ -587,11 +587,11 @@ // cArg: not defined #define PUKE_KSPROGRESS_CANCEL_ACK -1425 -// QTable View at 1500 +// TQTable View at 1500 // none yet -// QListBox at 1600 +// TQListBox at 1600 // Desc: insert string item // iWinId: window id @@ -935,7 +935,7 @@ // OBJECT base class #define PWIDGET_OBJECT 1 -// WIDGET defines a base QWidget class +// WIDGET defines a base TQWidget class #define PWIDGET_WIDGET 2 // FRAME defines a base class diff --git a/ksirc/puke/controller.cpp b/ksirc/puke/controller.cpp index 1e798be7..04017529 100644 --- a/ksirc/puke/controller.cpp +++ b/ksirc/puke/controller.cpp @@ -16,7 +16,7 @@ using namespace std; // iostream.h include cstring which puts strlen into // std:: namespace, which breaks Qt's strlen() call - // in qcstring.h (in gcc3's libstdc++) + // in tqcstring.h (in gcc3's libstdc++) #include #include @@ -50,7 +50,7 @@ using namespace std; // iostream.h include cstring which puts strlen into uint PukeController::uiBaseWinId = 10; // Gives a little seperation from the controller id -PukeController::PukeController(QString sock, QObject *parent, const char *name) : PObject( parent, name ) +PukeController::PukeController(TQString sock, TQObject *parent, const char *name) : PObject( parent, name ) { int len, prev_umask; struct sockaddr_un unix_addr; @@ -102,12 +102,12 @@ PukeController::PukeController(QString sock, QObject *parent, const char *name) fcntl(iListenFd, F_SETFL, O_NONBLOCK); // Set it non-block so that // accept() never blocks. - qsnListen = new QSocketNotifier(iListenFd, QSocketNotifier::Read, this, QString(name) + "_iListen"); - connect(qsnListen, SIGNAL(activated(int)), - this, SLOT(NewConnect(int))); + qsnListen = new TQSocketNotifier(iListenFd, TQSocketNotifier::Read, this, TQString(name) + "_iListen"); + connect(qsnListen, TQT_SIGNAL(activated(int)), + this, TQT_SLOT(NewConnect(int))); - connect(objFind, SIGNAL(inserted(QObject *)), - this, SLOT(slotInserted(QObject *))); + connect(objFind, TQT_SIGNAL(inserted(TQObject *)), + this, TQT_SLOT(slotInserted(TQObject *))); qidConnectFd.setAutoDelete(TRUE); @@ -124,8 +124,8 @@ PukeController::PukeController(QString sock, QObject *parent, const char *name) * Connect outputMessage to the acutal write buffer function * outputMessage signals from pobjects are chained until they finally reach us. */ - connect(this, SIGNAL(outputMessage(int, PukeMessage *)), - this, SLOT(writeBuffer(int, PukeMessage *))); + connect(this, TQT_SIGNAL(outputMessage(int, PukeMessage *)), + this, TQT_SLOT(writeBuffer(int, PukeMessage *))); initHdlr(); // Setup message command handlers. @@ -142,7 +142,7 @@ PukeController::PukeController(QString sock, QObject *parent, const char *name) } void -PukeController::slotInserted(QObject *obj) +PukeController::slotInserted(TQObject *obj) { emit inserted(obj); } @@ -154,7 +154,7 @@ PukeController::~PukeController() unlink(qsPukeSocket); } -QStrList PukeController::allObjects() +TQStrList PukeController::allObjects() { return objFinder::allObjects(); } @@ -174,12 +174,12 @@ void PukeController::NewConnect(int) // cfd() never blocks. fdStatus *fds = new fdStatus(); - fds->sr = new QSocketNotifier(cfd, QSocketNotifier::Read, this); - fds->sw = new QSocketNotifier(cfd, QSocketNotifier::Write, this); - connect(fds->sr, SIGNAL(activated(int)), - this, SLOT(Traffic(int))); - connect(fds->sw, SIGNAL(activated(int)), - this, SLOT(Writeable(int))); + fds->sr = new TQSocketNotifier(cfd, TQSocketNotifier::Read, this); + fds->sw = new TQSocketNotifier(cfd, TQSocketNotifier::Write, this); + connect(fds->sr, TQT_SIGNAL(activated(int)), + this, TQT_SLOT(Traffic(int))); + connect(fds->sw, TQT_SIGNAL(activated(int)), + this, TQT_SLOT(Writeable(int))); qidConnectFd.insert(cfd, fds); qsnListen->setEnabled(TRUE); @@ -350,7 +350,7 @@ void PukeController::Traffic(int fd) } -void PukeController::ServMessage(QString, int, QString) +void PukeController::ServMessage(TQString, int, TQString) { } @@ -585,7 +585,7 @@ void PukeController::hdlrPukeFetchWidget(int fd, PukeMessage *pm) // Let's go looking for the widget // Match any class with the right name - QObject *obj = 0x0; + TQObject *obj = 0x0; if(parent() && (strcmp(name, parent()->name()) == 0)){ obj = parent(); } @@ -609,8 +609,8 @@ void PukeController::hdlrPukeFetchWidget(int fd, PukeMessage *pm) } ws->type = iType; - connect(ws->pwidget, SIGNAL(outputMessage(int, PukeMessage*)), - this, SIGNAL(outputMessage(int, PukeMessage*))); + connect(ws->pwidget, TQT_SIGNAL(outputMessage(int, PukeMessage*)), + this, TQT_SIGNAL(outputMessage(int, PukeMessage*))); // insertPBoject(fd, uiBaseWinId, ws); // The widget list has to exist since we have ourselves in the list @@ -637,7 +637,7 @@ void PukeController::hdlrPukeDeleteWidget(int fd, PukeMessage *pm) throw(errorCommandFailed(PUKE_INVALID, INVALID_DEL_NO_CONTROL)); /* - QIntDict *qidWS = WidgetList[fd]; + TQIntDict *qidWS = WidgetList[fd]; if(qidWS == 0){ kdDebug(5008) << "WidgetRunner:: no such set of widget descriptors?" << endl; throw(errorCommandFailed(PUKE_INVALID, INVALID_DEL_NO_SUCH_CONNECTION)); @@ -691,7 +691,7 @@ void PukeController::closefd(int fd) /* * Now let's remove all traces of the widgets */ - QIntDict *qidWS = WidgetList[fd]; + TQIntDict *qidWS = WidgetList[fd]; if(qidWS == 0){ kdDebug(5008) << "WidgetRunner:: Close called twice?" << endl; bClosing = FALSE; @@ -702,7 +702,7 @@ void PukeController::closefd(int fd) do { - QIntDictIterator it(*qidWS); + TQIntDictIterator it(*qidWS); if(it.count() == 0){ kdDebug(5008) << "WidgetRunner: nothing left to delete\n" << endl; break; @@ -778,7 +778,7 @@ PWidget *PukeController::id2pwidget(widgetId *pwi){ void PukeController::insertPObject(int fd, int iWinId, WidgetS *obj){ // If no widget list exists for this fd, create one if(WidgetList[fd] == NULL){ - QIntDict *qidWS = new QIntDict; + TQIntDict *qidWS = new TQIntDict; qidWS->setAutoDelete(TRUE); WidgetList.insert(fd, qidWS); } @@ -796,8 +796,8 @@ void PukeController::insertPObject(int fd, int iWinId, WidgetS *obj){ // Now connect to the destroyed signal so we can remove the object from the lists // Once it is deleted - connect(obj->pwidget, SIGNAL(destroyed()), - this, SLOT(pobjectDestroyed())); + connect(obj->pwidget, TQT_SIGNAL(destroyed()), + this, TQT_SLOT(pobjectDestroyed())); } void PukeController::pobjectDestroyed(){ @@ -868,7 +868,7 @@ void PukeController::messageHandler(int fd, PukeMessage *pm) { return; } - QString libName = "ksirc/lib"+QString::fromLatin1(pm->cArg); + TQString libName = "ksirc/lib"+TQString::fromLatin1(pm->cArg); if (libName.right(3) == ".so") libName = libName.left(libName.length()-2)+"la"; @@ -959,8 +959,8 @@ widgetId PukeController::createWidget(widgetId wI, PukeMessage *pm) } ws->type = iType; - connect(ws->pwidget, SIGNAL(outputMessage(int, PukeMessage*)), - this, SIGNAL(outputMessage(int, PukeMessage*))); + connect(ws->pwidget, TQT_SIGNAL(outputMessage(int, PukeMessage*)), + this, TQT_SIGNAL(outputMessage(int, PukeMessage*))); // insertPBoject(fd, uiBaseWinId, ws); // The widget list has to exist since we have ourselves in the list diff --git a/ksirc/puke/controller.h b/ksirc/puke/controller.h index 80728224..5daa1629 100644 --- a/ksirc/puke/controller.h +++ b/ksirc/puke/controller.h @@ -8,12 +8,12 @@ #ifndef PUKE_CONTROLLER_H #define PUKE_CONTROLLER_H -#include -#include -#include -#include -#include -#include +#include +#include +#include +#include +#include +#include #include "pmessage.h" #include "pobject.h" @@ -24,9 +24,9 @@ class PukeController; class KLibrary; typedef struct { - QString server; + TQString server; bool writeable; - QSocketNotifier *sr,*sw; + TQSocketNotifier *sr,*sw; } fdStatus; @@ -81,7 +81,7 @@ class PukeController : public PObject { Q_OBJECT public: - PukeController(QString socket = "", QObject *parent=0, const char *name=0); + PukeController(TQString socket = "", TQObject *parent=0, const char *name=0); virtual ~PukeController(); bool running; @@ -102,20 +102,20 @@ public: */ PWidget *id2pwidget(widgetId *pwi); - QStrList allObjects(); + TQStrList allObjects(); signals: - void PukeMessages(QString server, int command, QString args); - void inserted(QObject *); + void PukeMessages(TQString server, int command, TQString args); + void inserted(TQObject *); public slots: - void ServMessage(QString, int, QString); + void ServMessage(TQString, int, TQString); protected slots: void Traffic(int); void Writeable(int); void NewConnect(int); - void slotInserted(QObject *obj); + void slotInserted(TQObject *obj); /** * When we delete a widget, this removes it from our internal @@ -132,11 +132,11 @@ protected slots: private: - QString qsPukeSocket; + TQString qsPukeSocket; int iListenFd; bool bClosing; // Set true if we are closing, we don't try and close twice at the same time. - QSocketNotifier *qsnListen; - QIntDict qidConnectFd; + TQSocketNotifier *qsnListen; + TQIntDict qidConnectFd; /** * Controller ID is defined as 1 @@ -145,15 +145,15 @@ private: // List of widgets and the fle descriptors they belong too - QIntDict > WidgetList; + TQIntDict > WidgetList; // I use a char * key that's the %p (hex address) of the pwidget - QDict revWidgetList; + TQDict revWidgetList; enum { keySize = 10 }; // Funtions used to create new widget - QIntDict widgetCF; // widgetCreatingFuntion List + TQIntDict widgetCF; // widgetCreatingFuntion List - QIntDict qidCommandTable; + TQIntDict qidCommandTable; void initHdlr(); @@ -181,11 +181,11 @@ private: /** * NOT APPLICAABLE */ - void setWidget(QObject *) { } + void setWidget(TQObject *) { } /** * NOT APPLICAABLE */ - virtual QObject *widget() { return 0x0; } + virtual TQObject *widget() { return 0x0; } /** * Inserts a PObject into our internal list diff --git a/ksirc/puke/palistbox.cpp b/ksirc/puke/palistbox.cpp index 8f3f22f1..9f43b124 100644 --- a/ksirc/puke/palistbox.cpp +++ b/ksirc/puke/palistbox.cpp @@ -13,7 +13,7 @@ PAListBox::createWidget(CreateArgs &ca) plb->setDeleteAble(FALSE); } else if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - lb = new aListBox((QWidget *) ca.parent->widget()); + lb = new aListBox((TQWidget *) ca.parent->widget()); else lb = new aListBox(); plb->setWidget(lb); @@ -123,7 +123,7 @@ void PAListBox::messageHandler(int fd, PukeMessage *pm) } } -void PAListBox::setWidget(QObject *_lb) +void PAListBox::setWidget(TQObject *_lb) { if(_lb != 0 && _lb->inherits("aListBox") == FALSE) { diff --git a/ksirc/puke/palistbox.h b/ksirc/puke/palistbox.h index 0731bef9..a902b018 100644 --- a/ksirc/puke/palistbox.h +++ b/ksirc/puke/palistbox.h @@ -19,7 +19,7 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_lb = 0x0); + virtual void setWidget(TQObject *_lb = 0x0); virtual aListBox *widget(); public slots: diff --git a/ksirc/puke/pbutton.cpp b/ksirc/puke/pbutton.cpp index 309f2ac7..edccbe81 100644 --- a/ksirc/puke/pbutton.cpp +++ b/ksirc/puke/pbutton.cpp @@ -1,7 +1,7 @@ #include -#include +#include #include @@ -11,11 +11,11 @@ PObject * PButton::createWidget(CreateArgs &ca) { PButton *pb = new PButton(ca.parent); - QButton *qb; + TQButton *qb; if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - qb = new QButton((QWidget *) ca.parent->widget()); + qb = new TQButton((TQWidget *) ca.parent->widget()); else - qb = new QButton(); + qb = new TQButton(); pb->setWidget(qb); pb->setWidgetId(ca.pwI); return pb; @@ -60,7 +60,7 @@ void PButton::messageHandler(int fd, PukeMessage *pm) if(checkWidget() == FALSE) return; - widget()->setPixmap(QPixmap(pm->cArg)); + widget()->setPixmap(TQPixmap(pm->cArg)); pmRet.iCommand = - pm->iCommand; pmRet.iWinId = pm->iWinId; @@ -82,24 +82,24 @@ void PButton::messageHandler(int fd, PukeMessage *pm) } } -void PButton::setWidget(QObject *_qb) +void PButton::setWidget(TQObject *_qb) { - if(_qb != 0 && _qb->inherits("QButton") == FALSE) + if(_qb != 0 && _qb->inherits("TQButton") == FALSE) { errorInvalidSet(_qb); return; } - button = (QButton *) _qb; + button = (TQButton *) _qb; if(button != 0){ - connect(button, SIGNAL(pressed()), - this, SLOT(buttonPressed())); - connect(button, SIGNAL(released()), - this, SLOT(buttonReleased())); - connect(button, SIGNAL(clicked()), - this, SLOT(buttonClicked())); - connect(button, SIGNAL(toggled(bool)), - this, SLOT(buttonToggled(bool))); + connect(button, TQT_SIGNAL(pressed()), + this, TQT_SLOT(buttonPressed())); + connect(button, TQT_SIGNAL(released()), + this, TQT_SLOT(buttonReleased())); + connect(button, TQT_SIGNAL(clicked()), + this, TQT_SLOT(buttonClicked())); + connect(button, TQT_SIGNAL(toggled(bool)), + this, TQT_SLOT(buttonToggled(bool))); } PWidget::setWidget(_qb); @@ -107,7 +107,7 @@ void PButton::setWidget(QObject *_qb) } -QButton *PButton::widget() +TQButton *PButton::widget() { return button; } diff --git a/ksirc/puke/pbutton.h b/ksirc/puke/pbutton.h index e43bd681..addc7713 100644 --- a/ksirc/puke/pbutton.h +++ b/ksirc/puke/pbutton.h @@ -3,7 +3,7 @@ class PButton; -#include +#include #include "pmessage.h" #include "pwidget.h" #include "pobject.h" @@ -21,8 +21,8 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_qb = 0x0); - virtual QButton *widget(); + virtual void setWidget(TQObject *_qb = 0x0); + virtual TQButton *widget(); public slots: void buttonPressed(); @@ -31,7 +31,7 @@ public slots: void buttonToggled(bool); private: - QButton *button; + TQButton *button; void buttonMessage(int iCommand); bool checkWidget(); diff --git a/ksirc/puke/pframe.cpp b/ksirc/puke/pframe.cpp index fcff1d96..d0dc79e3 100644 --- a/ksirc/puke/pframe.cpp +++ b/ksirc/puke/pframe.cpp @@ -5,12 +5,12 @@ PObject * PFrame::createWidget(CreateArgs &ca) { PFrame *pw = new PFrame(ca.parent); - QFrame *tf; + TQFrame *tf; if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - tf = new QFrame((QWidget *) ca.parent->widget()); + tf = new TQFrame((TQWidget *) ca.parent->widget()); else - tf = new QFrame(); + tf = new TQFrame(); pw->setWidget(tf); pw->setWidgetId(ca.pwI); pw->setPukeController(ca.pc); @@ -61,20 +61,20 @@ void PFrame::messageHandler(int fd, PukeMessage *pm) } } -void PFrame::setWidget(QObject *w) +void PFrame::setWidget(TQObject *w) { - if(w != 0 && w->inherits("QFrame") == FALSE) + if(w != 0 && w->inherits("TQFrame") == FALSE) { errorInvalidSet(w); return; } - frame = (QFrame *) w; - PWidget::setWidget((QWidget *) w); + frame = (TQFrame *) w; + PWidget::setWidget((TQWidget *) w); } -QFrame *PFrame::widget() +TQFrame *PFrame::widget() { // kdDebug(5008) << "PFrame widget called" << endl; return frame; diff --git a/ksirc/puke/pframe.h b/ksirc/puke/pframe.h index e98750aa..8d7fbc82 100644 --- a/ksirc/puke/pframe.h +++ b/ksirc/puke/pframe.h @@ -3,7 +3,7 @@ class PFrame; -#include +#include #include "pmessage.h" #include "pwidget.h" @@ -18,11 +18,11 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *w = 0x0); - virtual QFrame *widget(); + virtual void setWidget(TQObject *w = 0x0); + virtual TQFrame *widget(); private: - QFrame *frame; + TQFrame *frame; }; #endif diff --git a/ksirc/puke/pkfiledialog.cpp b/ksirc/puke/pkfiledialog.cpp index c99aea9f..f78ae895 100644 --- a/ksirc/puke/pkfiledialog.cpp +++ b/ksirc/puke/pkfiledialog.cpp @@ -16,7 +16,7 @@ PKFileDialog::createWidget(CreateArgs &ca) pw->setDeleteAble(FALSE); } else // Never takes a parent in Puke - kfbd = new KFileDialog("/", QString::null, 0L, "PukeKFileDialog", TRUE); + kfbd = new KFileDialog("/", TQString::null, 0L, "PukeKFileDialog", TRUE); pw->setWidget(kfbd); pw->setWidgetId(ca.pwI); return pw; @@ -42,7 +42,7 @@ PKFileDialog::~PKFileDialog() void PKFileDialog::messageHandler(int fd, PukeMessage *pm) { - QString selFile; + TQString selFile; PukeMessage pmRet; if(widget() == 0){ kdDebug(5008) << "PKFileDialog: No Widget set" << endl; @@ -102,7 +102,7 @@ void PKFileDialog::messageHandler(int fd, PukeMessage *pm) } } -void PKFileDialog::setWidget(QObject *_kbfd) +void PKFileDialog::setWidget(TQObject *_kbfd) { if(_kbfd != 0 && _kbfd->inherits("KFileBaseDialog") == FALSE) { diff --git a/ksirc/puke/pkfiledialog.h b/ksirc/puke/pkfiledialog.h index c8dbea3f..dbfd7dd5 100644 --- a/ksirc/puke/pkfiledialog.h +++ b/ksirc/puke/pkfiledialog.h @@ -19,7 +19,7 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_f = 0x0); + virtual void setWidget(TQObject *_f = 0x0); virtual KFileDialog *widget(); public slots: diff --git a/ksirc/puke/plabel.cpp b/ksirc/puke/plabel.cpp index 17ca851d..4d2bba48 100644 --- a/ksirc/puke/plabel.cpp +++ b/ksirc/puke/plabel.cpp @@ -1,4 +1,4 @@ -#include +#include #include @@ -9,15 +9,15 @@ PObject * PLabel::createWidget(CreateArgs &ca) { PLabel *pw = new PLabel(ca.parent); - QLabel *le; - if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("QLabel") == TRUE){ - le = (QLabel *) ca.fetchedObj; + TQLabel *le; + if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("TQLabel") == TRUE){ + le = (TQLabel *) ca.fetchedObj; pw->setDeleteAble(FALSE); } else if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - le = new QLabel((QWidget *) ca.parent->widget()); + le = new TQLabel((TQWidget *) ca.parent->widget()); else - le = new QLabel((QWidget *)0L); + le = new TQLabel((TQWidget *)0L); pw->setWidget(le); pw->setWidgetId(ca.pwI); return pw; @@ -61,7 +61,7 @@ void PLabel::messageHandler(int fd, PukeMessage *pm) if(!checkWidget()) return; - widget()->setPixmap(QPixmap(pm->cArg)); + widget()->setPixmap(TQPixmap(pm->cArg)); pmRet.iCommand = - pm->iCommand; pmRet.iWinId = pm->iWinId; pmRet.iArg = 0; @@ -72,7 +72,7 @@ void PLabel::messageHandler(int fd, PukeMessage *pm) if(!checkWidget()) return; - widget()->setMovie(QMovie(pm->cArg)); + widget()->setMovie(TQMovie(pm->cArg)); pmRet.iCommand = - pm->iCommand; pmRet.iWinId = pm->iWinId; pmRet.iArg = 0; @@ -95,21 +95,21 @@ void PLabel::messageHandler(int fd, PukeMessage *pm) } } -void PLabel::setWidget(QObject *_l) +void PLabel::setWidget(TQObject *_l) { - if(_l != 0 && _l->inherits("QLabel") == FALSE) + if(_l != 0 && _l->inherits("TQLabel") == FALSE) { errorInvalidSet(_l); return; } - label = (QLabel *) _l; + label = (TQLabel *) _l; PWidget::setWidget(_l); } -QLabel *PLabel::widget() +TQLabel *PLabel::widget() { return label; } diff --git a/ksirc/puke/plabel.h b/ksirc/puke/plabel.h index c53705b1..f68ffd28 100644 --- a/ksirc/puke/plabel.h +++ b/ksirc/puke/plabel.h @@ -3,7 +3,7 @@ class PLabel; -#include +#include #include "pmessage.h" #include "pframe.h" #include "controller.h" @@ -19,8 +19,8 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_obj = 0); - virtual QLabel *widget(); + virtual void setWidget(TQObject *_obj = 0); + virtual TQLabel *widget(); public slots: @@ -28,7 +28,7 @@ protected: bool checkWidget(); private: - QLabel *label; + TQLabel *label; }; #endif diff --git a/ksirc/puke/playout.cpp b/ksirc/puke/playout.cpp index 9690f418..ae4fa6d1 100644 --- a/ksirc/puke/playout.cpp +++ b/ksirc/puke/playout.cpp @@ -4,7 +4,7 @@ #include "playout.h" #include "commands.h" -PLayout::PLayout(QObject *pobject) +PLayout::PLayout(TQObject *pobject) : PObject(pobject) { // Connect slots as needed @@ -24,7 +24,7 @@ PLayout::~PLayout() PObject *PLayout::createWidget(CreateArgs &ca) { PLayout *pw = new PLayout(ca.parent); - QBoxLayout *qbl; + TQBoxLayout *qbl; int direction, border, iType, iParent; // Retreive the border and direction information out of the // carg string @@ -33,12 +33,12 @@ PObject *PLayout::createWidget(CreateArgs &ca) if((ca.parent != 0) && (ca.parent->widget()->isWidgetType() == TRUE)){ - qbl = new QBoxLayout((QWidget *) ca.parent->widget(), (QBoxLayout::Direction) direction, border); + qbl = new TQBoxLayout((TQWidget *) ca.parent->widget(), (TQBoxLayout::Direction) direction, border); // kdDebug(5008) << "Creating layout with parent: " << parent.iWinId << endl; } else{ - qbl = new QBoxLayout((QBoxLayout::Direction) direction, border); + qbl = new TQBoxLayout((TQBoxLayout::Direction) direction, border); // kdDebug(5008) << "Creating layout NO PARENT" << endl; } pw->setWidget(qbl); @@ -88,7 +88,7 @@ void PLayout::messageHandler(int fd, PukeMessage *pm) } PObject *pld = controller()->id2pobject(fd, pm->iWinId); PObject *pls = controller()->id2pobject(fd, pm->iArg); - if( (pld->widget()->inherits("QBoxLayout") == FALSE) || (pls->widget()->inherits("QBoxLayout") == FALSE)) + if( (pld->widget()->inherits("TQBoxLayout") == FALSE) || (pls->widget()->inherits("TQBoxLayout") == FALSE)) throw(errorCommandFailed(PUKE_LAYOUT_ADDLAYOUT_ACK, 1)); PLayout *plbd = (PLayout *) pld; PLayout *plbs = (PLayout *) pls; @@ -133,21 +133,21 @@ void PLayout::messageHandler(int fd, PukeMessage *pm) } -void PLayout::setWidget(QObject *_layout) +void PLayout::setWidget(TQObject *_layout) { // kdDebug(5008) << "PObject setwidget called" << endl; - if(_layout != 0 && _layout->inherits("QBoxLayout") == FALSE) + if(_layout != 0 && _layout->inherits("TQBoxLayout") == FALSE) { errorInvalidSet(_layout); return; } - layout = (QBoxLayout *) _layout; + layout = (TQBoxLayout *) _layout; PObject::setWidget(_layout); } -QBoxLayout *PLayout::widget() +TQBoxLayout *PLayout::widget() { return layout; } diff --git a/ksirc/puke/playout.h b/ksirc/puke/playout.h index 4aec01a1..90a606b8 100644 --- a/ksirc/puke/playout.h +++ b/ksirc/puke/playout.h @@ -3,8 +3,8 @@ class PLayout; -#include -#include +#include +#include #include "pmessage.h" #include "pobject.h" @@ -14,7 +14,7 @@ class PLayout : public PObject public: static PObject *createWidget(CreateArgs &ca); - PLayout(QObject *parent = 0); + PLayout(TQObject *parent = 0); virtual ~PLayout(); /** @@ -26,16 +26,16 @@ public: /** * Sets the current opbect */ - virtual void setWidget(QObject *qb = 0x0); + virtual void setWidget(TQObject *qb = 0x0); /** * Returns the current object */ - virtual QBoxLayout *widget(); + virtual TQBoxLayout *widget(); private: - QBoxLayout *layout; + TQBoxLayout *layout; }; diff --git a/ksirc/puke/plined.cpp b/ksirc/puke/plined.cpp index 3f3e6a09..56a4ddc0 100644 --- a/ksirc/puke/plined.cpp +++ b/ksirc/puke/plined.cpp @@ -9,11 +9,11 @@ PObject * PLineEdit::createWidget(CreateArgs &ca) { PLineEdit *pw = new PLineEdit(ca.parent); - QLineEdit *le; + TQLineEdit *le; if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - le = new QLineEdit((QWidget *) ca.parent->widget()); + le = new TQLineEdit((TQWidget *) ca.parent->widget()); else - le = new QLineEdit(0L); + le = new TQLineEdit(0L); pw->setWidget(le); pw->setWidgetId(ca.pwI); return pw; @@ -59,7 +59,7 @@ void PLineEdit::messageHandler(int fd, PukeMessage *pm) kdDebug(5008) << "PLineEdit: No Widget set" << endl; return; } - widget()->setEchoMode((QLineEdit::EchoMode) pm->iArg); + widget()->setEchoMode((TQLineEdit::EchoMode) pm->iArg); pmRet.iCommand = - pm->iCommand; pmRet.iWinId = pm->iWinId; pmRet.iArg = widget()->echoMode(); @@ -101,27 +101,27 @@ void PLineEdit::messageHandler(int fd, PukeMessage *pm) } } -void PLineEdit::setWidget(QObject *_le) +void PLineEdit::setWidget(TQObject *_le) { - if(_le != 0 && _le->inherits("QLineEdit") == FALSE) + if(_le != 0 && _le->inherits("TQLineEdit") == FALSE) { errorInvalidSet(_le); return; } - lineedit = (QLineEdit *) _le; + lineedit = (TQLineEdit *) _le; if(lineedit != 0){ - connect(lineedit, SIGNAL(textChanged(const char *)), - this, SLOT(updateText(const char *))); - connect(lineedit, SIGNAL(returnPressed()), - this, SLOT(returnPress())); + connect(lineedit, TQT_SIGNAL(textChanged(const char *)), + this, TQT_SLOT(updateText(const char *))); + connect(lineedit, TQT_SIGNAL(returnPressed()), + this, TQT_SLOT(returnPress())); } PWidget::setWidget(_le); } -QLineEdit *PLineEdit::widget() +TQLineEdit *PLineEdit::widget() { return lineedit; } diff --git a/ksirc/puke/plined.h b/ksirc/puke/plined.h index 78f04bdf..91ca7413 100644 --- a/ksirc/puke/plined.h +++ b/ksirc/puke/plined.h @@ -3,7 +3,7 @@ class PLineEdit; -#include +#include #include "pmessage.h" #include "pwidget.h" #include "controller.h" @@ -19,15 +19,15 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_f); - virtual QLineEdit *widget(); + virtual void setWidget(TQObject *_f); + virtual TQLineEdit *widget(); public slots: void updateText(const char *); void returnPress(); private: - QLineEdit *lineedit; + TQLineEdit *lineedit; }; #endif diff --git a/ksirc/puke/plistbox.cpp b/ksirc/puke/plistbox.cpp index 482e08c7..d0b98305 100644 --- a/ksirc/puke/plistbox.cpp +++ b/ksirc/puke/plistbox.cpp @@ -7,15 +7,15 @@ PObject * PListBox::createWidget(CreateArgs &ca) { PListBox *plb = new PListBox(ca.parent); - QListBox *lb; - if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("QListBox") == TRUE){ - lb = (QListBox *) ca.fetchedObj; + TQListBox *lb; + if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("TQListBox") == TRUE){ + lb = (TQListBox *) ca.fetchedObj; plb->setDeleteAble(FALSE); } else if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - lb = new QListBox((QWidget *) ca.parent->widget()); + lb = new TQListBox((TQWidget *) ca.parent->widget()); else - lb = new QListBox(); + lb = new TQListBox(); plb->setWidget(lb); plb->setWidgetId(ca.pwI); return plb; @@ -71,7 +71,7 @@ void PListBox::messageHandler(int fd, PukeMessage *pm) if(!checkWidget()) return; - widget()->insertItem(QPixmap(pm->cArg), pm->iArg); + widget()->insertItem(TQPixmap(pm->cArg), pm->iArg); pmRet.iCommand = - pm->iCommand; pmRet.iWinId = pm->iWinId; pmRet.iArg = widget()->count(); @@ -122,7 +122,7 @@ void PListBox::messageHandler(int fd, PukeMessage *pm) } break; case PUKE_LISTBOX_SET_SCROLLBAR: - widget()->setVScrollBarMode( (bool) pm->iArg ? QListBox::AlwaysOn : QListBox::AlwaysOff ); + widget()->setVScrollBarMode( (bool) pm->iArg ? TQListBox::AlwaysOn : TQListBox::AlwaysOff ); pmRet.iCommand = PUKE_LISTBOX_SET_SCROLLBAR_ACK; pmRet.iWinId = pm->iWinId; pmRet.iArg = 0; @@ -130,7 +130,7 @@ void PListBox::messageHandler(int fd, PukeMessage *pm) emit outputMessage(fd, &pmRet); break; case PUKE_LISTBOX_SET_AUTO_SCROLLBAR: - widget()->setVScrollBarMode( (bool) pm->iArg ? QListBox::Auto : QListBox::AlwaysOff ); + widget()->setVScrollBarMode( (bool) pm->iArg ? TQListBox::Auto : TQListBox::AlwaysOff ); pmRet.iCommand = PUKE_LISTBOX_SET_AUTO_SCROLLBAR_ACK; pmRet.iWinId = pm->iWinId; pmRet.iArg = 0; @@ -150,27 +150,27 @@ void PListBox::messageHandler(int fd, PukeMessage *pm) } } -void PListBox::setWidget(QObject *_lb) +void PListBox::setWidget(TQObject *_lb) { - if(_lb != 0 && _lb->inherits("QListBox") == FALSE) + if(_lb != 0 && _lb->inherits("TQListBox") == FALSE) { errorInvalidSet(_lb); return; } - lb = (QListBox *) _lb; + lb = (TQListBox *) _lb; if(lb != 0){ - connect(lb, SIGNAL(highlighted(int)), - this, SLOT(highlighted(int))); - connect(lb, SIGNAL(selected(int)), - this, SLOT(selected(int))); + connect(lb, TQT_SIGNAL(highlighted(int)), + this, TQT_SLOT(highlighted(int))); + connect(lb, TQT_SIGNAL(selected(int)), + this, TQT_SLOT(selected(int))); } PFrame::setWidget(lb); } -QListBox *PListBox::widget() +TQListBox *PListBox::widget() { return lb; } diff --git a/ksirc/puke/plistbox.h b/ksirc/puke/plistbox.h index cad454a8..c7683b22 100644 --- a/ksirc/puke/plistbox.h +++ b/ksirc/puke/plistbox.h @@ -3,7 +3,7 @@ class PListBox; -#include +#include #include "pmessage.h" #include "ptablevw.h" #include "controller.h" @@ -19,8 +19,8 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_lb); - virtual QListBox *widget(); + virtual void setWidget(TQObject *_lb); + virtual TQListBox *widget(); public slots: void highlighted(int); @@ -30,7 +30,7 @@ protected: bool checkWidget(); private: - QListBox *lb; + TQListBox *lb; }; diff --git a/ksirc/puke/pmenudta.cpp b/ksirc/puke/pmenudta.cpp index 30b375fc..576ebc39 100644 --- a/ksirc/puke/pmenudta.cpp +++ b/ksirc/puke/pmenudta.cpp @@ -1,14 +1,14 @@ #include "pmenudta.h" #include "pobject.h" -#include +#include PMenuData::PMenuData(PObject *_child) : PObject() { child = _child; - connect(this, SIGNAL(outputMessage(int, PukeMessage*)), - child, SIGNAL(outputMessage(int, PukeMessage*))); + connect(this, TQT_SIGNAL(outputMessage(int, PukeMessage*)), + child, TQT_SIGNAL(outputMessage(int, PukeMessage*))); } PMenuData::~PMenuData() @@ -28,7 +28,7 @@ bool PMenuData::menuMessageHandler(int fd, PukeMessage *pm) switch(pm->iCommand){ case PUKE_MENUDATA_INSERT_TEXT: { - QPopupMenu *widget = (QPopupMenu *) child->widget(); + TQPopupMenu *widget = (TQPopupMenu *) child->widget(); id = widget->insertItem(pm->cArg); if(pm->iArg > 0){ widget->setAccel(pm->iArg, id); @@ -43,8 +43,8 @@ bool PMenuData::menuMessageHandler(int fd, PukeMessage *pm) } case PUKE_MENUDATA_INSERT_PIXMAP: { - QPopupMenu *widget = (QPopupMenu *) child->widget(); - id = widget->insertItem(QPixmap(pm->cArg)); + TQPopupMenu *widget = (TQPopupMenu *) child->widget(); + id = widget->insertItem(TQPixmap(pm->cArg)); if(pm->iArg > 0){ widget->setAccel(pm->iArg, id); } @@ -58,7 +58,7 @@ bool PMenuData::menuMessageHandler(int fd, PukeMessage *pm) } case PUKE_MENUDATA_REMOVE_ITEM: { - QPopupMenu *widget = (QPopupMenu *) child->widget(); + TQPopupMenu *widget = (TQPopupMenu *) child->widget(); widget->removeItem(pm->iArg); pmRet.iCommand = PUKE_MENUDATA_REMOVE_ITEM_ACK; diff --git a/ksirc/puke/pmenudta.h b/ksirc/puke/pmenudta.h index 0c3bfc6a..03227134 100644 --- a/ksirc/puke/pmenudta.h +++ b/ksirc/puke/pmenudta.h @@ -3,8 +3,8 @@ class PMenuData; -#include -#include +#include +#include #include "pmessage.h" #include "pframe.h" #include "pobject.h" @@ -18,17 +18,17 @@ class PMenuData; class PMenuDataHelper : public QMenuData { public: - PMenuDataHelper(QMenuData &qmd) { - memcpy(this, &qmd, sizeof(QMenuData)); + PMenuDataHelper(TQMenuData &qmd) { + memcpy(this, &qmd, sizeof(TQMenuData)); } int active() { - return QMenuData::actItem; + return TQMenuData::actItem; } int actItem; }; /** - * We're subclased off QMenuData so we can access it's internal proteted vars + * We're subclased off TQMenuData so we can access it's internal proteted vars * We do not initialize NOR create it!!!! */ @@ -42,12 +42,12 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); virtual bool menuMessageHandler(int fd, PukeMessage *pm); -// virtual void setWidget(QMenuData *_qmd); - // virtual QMenuData *widget(); +// virtual void setWidget(TQMenuData *_qmd); + // virtual TQMenuData *widget(); virtual int activeItem() { - return PMenuDataHelper(*((QMenuData *) child->widget())).active(); + return PMenuDataHelper(*((TQMenuData *) child->widget())).active(); } private: diff --git a/ksirc/puke/pmessage.h b/ksirc/puke/pmessage.h index 5c777b24..a93cd154 100644 --- a/ksirc/puke/pmessage.h +++ b/ksirc/puke/pmessage.h @@ -20,16 +20,16 @@ const uint iPukeHeader = 42U; #if 0 class errorInvalidSet { public: - errorInvalidSet(QObject *_from, const char *_to) + errorInvalidSet(TQObject *_from, const char *_to) : __from(_from), __to(_to) { } - QObject *from() { return __from; } + TQObject *from() { return __from; } const char *to() { return __to; } private: - QObject *__from; + TQObject *__from; const char *__to; }; diff --git a/ksirc/puke/pobject.cpp b/ksirc/puke/pobject.cpp index f2481a04..9e46e042 100644 --- a/ksirc/puke/pobject.cpp +++ b/ksirc/puke/pobject.cpp @@ -2,8 +2,8 @@ #include "commands.h" -PObject::PObject(QObject *pobject, const char *name) - : QObject(pobject, name) +PObject::PObject(TQObject *pobject, const char *name) + : TQObject(pobject, name) { // Connect slots as needed obj = 0; @@ -24,11 +24,11 @@ PObject::~PObject() PObject *PObject::createWidget(CreateArgs &ca) { PObject *pw = new PObject(ca.parent); - QObject *o; + TQObject *o; if(ca.parent != 0) - o = new QObject(ca.parent->widget()); + o = new TQObject(ca.parent->widget()); else - o = new QObject(); + o = new TQObject(); pw->setWidget(o); pw->setWidgetId(ca.pwI); pw->setPukeController(ca.pc); @@ -78,23 +78,23 @@ void PObject::messageHandler(int fd, PukeMessage *pm) } } -void PObject::setWidget(QObject *_o) +void PObject::setWidget(TQObject *_o) { // Disconnect everything from the object we where listning too // Just in case it fires something off, we don't want to get it if(widget() != 0){ - disconnect(widget(), SIGNAL(destroyed()), - this, SLOT(swidgetDestroyed())); + disconnect(widget(), TQT_SIGNAL(destroyed()), + this, TQT_SLOT(swidgetDestroyed())); } obj = _o; if(obj != 0){ - connect(widget(), SIGNAL(destroyed()), - this, SLOT(swidgetDestroyed())); + connect(widget(), TQT_SIGNAL(destroyed()), + this, TQT_SLOT(swidgetDestroyed())); } } -QObject *PObject::widget() +TQObject *PObject::widget() { // kdDebug(5008) << "PObject widget called" << endl; return obj; @@ -129,9 +129,9 @@ void PObject::manTerm() { manualTerm = TRUE; } -void PObject::errorInvalidSet(QObject *_w) +void PObject::errorInvalidSet(TQObject *_w) { - m_error = QString("Tried setting a %1 to %2").arg(_w->className()).arg(className()); + m_error = TQString("Tried setting a %1 to %2").arg(_w->className()).arg(className()); m_hasError = true; } #include "pobject.moc" diff --git a/ksirc/puke/pobject.h b/ksirc/puke/pobject.h index 8e5c7c5a..d27fab58 100644 --- a/ksirc/puke/pobject.h +++ b/ksirc/puke/pobject.h @@ -5,7 +5,7 @@ class PObject; class PukeController; class CreateArgs; -#include +#include #include "pmessage.h" @@ -26,18 +26,18 @@ public: /** * name of the widget which was fetched from kSirc, this has to be set explicitly */ - QObject *fetchedObj; + TQObject *fetchedObj; }; class PObject : public QObject { Q_OBJECT public: - PObject(QObject *parent = 0, const char *name = 0); + PObject(TQObject *parent = 0, const char *name = 0); virtual ~PObject(); /** - * Creates a new QObject and returns a PObject + * Creates a new TQObject and returns a PObject */ static PObject *createWidget(CreateArgs &ca); @@ -50,12 +50,12 @@ class PObject : public QObject /** * Sets the current opbect */ - virtual void setWidget(QObject *w); + virtual void setWidget(TQObject *w); /** * Returns the current object */ - virtual QObject *widget(); + virtual TQObject *widget(); /** * Sets the window id @@ -90,7 +90,7 @@ class PObject : public QObject /** * Returns error description */ - QString error() { + TQString error() { m_hasError = false; return m_error; } @@ -117,16 +117,16 @@ class PObject : public QObject protected: PukeController *controller(); - void errorInvalidSet(QObject *_w); + void errorInvalidSet(TQObject *_w); private: - QObject *obj; + TQObject *obj; PukeController *pController; widgetId wI; bool manualTerm; bool deleteAble; - QString m_error; + TQString m_error; bool m_hasError; }; diff --git a/ksirc/puke/pobjfinder.cpp b/ksirc/puke/pobjfinder.cpp index 0f510ea4..6870e142 100644 --- a/ksirc/puke/pobjfinder.cpp +++ b/ksirc/puke/pobjfinder.cpp @@ -19,8 +19,8 @@ PObjFinder::PObjFinder(PObject *parent) // We don't actually encase a widget since all the ObjFinder interface // is static setWidget(0x0); - connect(controller(), SIGNAL(inserted(QObject *)), - this, SLOT(newObject(QObject *))); + connect(controller(), TQT_SIGNAL(inserted(TQObject *)), + this, TQT_SLOT(newObject(TQObject *))); } PObjFinder::~PObjFinder() @@ -33,8 +33,8 @@ void PObjFinder::messageHandler(int fd, PukeMessage *pm) switch(pm->iCommand){ case PUKE_OBJFINDER_ALLOBJECTS: { - QString qscArg; - QStrList allObj = controller()->allObjects(); + TQString qscArg; + TQStrList allObj = controller()->allObjects(); for(uint i = 0; i <= allObj.count(); i++){ qscArg += allObj.at(i); qscArg += "\n"; @@ -54,7 +54,7 @@ void PObjFinder::messageHandler(int fd, PukeMessage *pm) } } -void PObjFinder::setWidget(QObject *_obj) +void PObjFinder::setWidget(TQObject *_obj) { PObject::setWidget(_obj); } @@ -66,8 +66,8 @@ objFinder *PObjFinder::widget() } -void PObjFinder::newObject(QObject *name){ - QString info; +void PObjFinder::newObject(TQObject *name){ + TQString info; info = name->className(); info += "::"; diff --git a/ksirc/puke/pobjfinder.h b/ksirc/puke/pobjfinder.h index 9149aa86..32b4ff86 100644 --- a/ksirc/puke/pobjfinder.h +++ b/ksirc/puke/pobjfinder.h @@ -18,11 +18,11 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_obj = 0); + virtual void setWidget(TQObject *_obj = 0); virtual objFinder *widget(); public slots: - virtual void newObject(QObject *obj); + virtual void newObject(TQObject *obj); protected: bool checkWidget(); diff --git a/ksirc/puke/ppopmenu.cpp b/ksirc/puke/ppopmenu.cpp index 4c07d800..cabf4d94 100644 --- a/ksirc/puke/ppopmenu.cpp +++ b/ksirc/puke/ppopmenu.cpp @@ -1,5 +1,5 @@ #include -#include +#include #include "ppopmenu.h" @@ -7,15 +7,15 @@ PObject * PPopupMenu::createWidget(CreateArgs &ca) { PPopupMenu *pm = new PPopupMenu(ca.parent); - QPopupMenu *qpm; - if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("QPopupMenu") == TRUE){ - qpm= (QPopupMenu *) ca.fetchedObj; + TQPopupMenu *qpm; + if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("TQPopupMenu") == TRUE){ + qpm= (TQPopupMenu *) ca.fetchedObj; pm->setDeleteAble(FALSE); } else if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - qpm = new QPopupMenu((QWidget *) ca.parent->widget()); + qpm = new TQPopupMenu((TQWidget *) ca.parent->widget()); else - qpm = new QPopupMenu(); + qpm = new TQPopupMenu(); pm->setWidget(qpm); pm->setWidgetId(ca.pwI); return pm; @@ -64,7 +64,7 @@ void PPopupMenu::messageHandler(int fd, PukeMessage *pm) return; } - widget()->popup(QCursor::pos(), 0); + widget()->popup(TQCursor::pos(), 0); pmRet.iCommand = - pm->iCommand; pmRet.iWinId = pm->iWinId; @@ -79,24 +79,24 @@ void PPopupMenu::messageHandler(int fd, PukeMessage *pm) } } -void PPopupMenu::setWidget(QObject *_menu) +void PPopupMenu::setWidget(TQObject *_menu) { - if(_menu != 0 && _menu->inherits("QPopupMenu") == FALSE) + if(_menu != 0 && _menu->inherits("TQPopupMenu") == FALSE) { errorInvalidSet(_menu); return; } - menu = (QPopupMenu *) _menu; + menu = (TQPopupMenu *) _menu; if(menu != 0x0){ - connect(menu, SIGNAL(activated(int)), - this, SLOT(got_activated(int))); + connect(menu, TQT_SIGNAL(activated(int)), + this, TQT_SLOT(got_activated(int))); } PFrame::setWidget(menu); } -QPopupMenu *PPopupMenu::widget() +TQPopupMenu *PPopupMenu::widget() { return menu; } diff --git a/ksirc/puke/ppopmenu.h b/ksirc/puke/ppopmenu.h index 9044b935..4f5af16e 100644 --- a/ksirc/puke/ppopmenu.h +++ b/ksirc/puke/ppopmenu.h @@ -3,7 +3,7 @@ class PPopupMenu; -#include +#include #include "pobject.h" #include "pmessage.h" @@ -21,14 +21,14 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_menu); - virtual QPopupMenu *widget(); + virtual void setWidget(TQObject *_menu); + virtual TQPopupMenu *widget(); protected slots: void got_activated ( int itemId ); private: - QPopupMenu *menu; + TQPopupMenu *menu; PMenuData *pmd; }; diff --git a/ksirc/puke/pprogress.cpp b/ksirc/puke/pprogress.cpp index 75c7fa4b..09ed39d2 100644 --- a/ksirc/puke/pprogress.cpp +++ b/ksirc/puke/pprogress.cpp @@ -11,7 +11,7 @@ PProgress::createWidget(CreateArgs &ca) PProgress *pw = new PProgress(ca.parent); KSProgress *ksp; if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - ksp = new KSProgress((QWidget *) ca.parent->widget()); + ksp = new KSProgress((TQWidget *) ca.parent->widget()); else ksp = new KSProgress(); pw->setWidget(ksp); @@ -66,7 +66,7 @@ void PProgress::messageHandler(int fd, PukeMessage *pm) break; } case PUKE_KSPROGRESS_SET_TOPTEXT: - widget()->setTopText(QString(pm->cArg)); + widget()->setTopText(TQString(pm->cArg)); pmRet.iCommand = PUKE_KSPROGRESS_SET_TOPTEXT; pmRet.iWinId = pm->iWinId; pmRet.iArg = 0; @@ -74,7 +74,7 @@ void PProgress::messageHandler(int fd, PukeMessage *pm) emit outputMessage(fd, &pmRet); break; case PUKE_KSPROGRESS_SET_BOTTEXT: - widget()->setBotText(QString(pm->cArg)); + widget()->setBotText(TQString(pm->cArg)); pmRet.iCommand = PUKE_KSPROGRESS_SET_BOTTEXT; pmRet.iWinId = pm->iWinId; pmRet.iArg = 0; @@ -104,7 +104,7 @@ void PProgress::cancelPressed(){ emit outputMessage(widgetIden().fd, &pmRet); } -void PProgress::setWidget(QObject *_f) +void PProgress::setWidget(TQObject *_f) { // kdDebug(5008) << "PProgress setWidget called" << endl; if(_f != 0 && _f->inherits("KSProgress") == FALSE) @@ -115,8 +115,8 @@ void PProgress::setWidget(QObject *_f) ksp = (KSProgress *) _f; if(widget() != 0){ - connect(widget(), SIGNAL(cancel()), - this, SLOT(cancelPressed())); + connect(widget(), TQT_SIGNAL(cancel()), + this, TQT_SLOT(cancelPressed())); } PWidget::setWidget(ksp); diff --git a/ksirc/puke/pprogress.h b/ksirc/puke/pprogress.h index f81fd976..8542abab 100644 --- a/ksirc/puke/pprogress.h +++ b/ksirc/puke/pprogress.h @@ -19,7 +19,7 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_f); + virtual void setWidget(TQObject *_f); virtual KSProgress *widget(); protected slots: diff --git a/ksirc/puke/ppushbt.cpp b/ksirc/puke/ppushbt.cpp index 48cf6121..346abcd3 100644 --- a/ksirc/puke/ppushbt.cpp +++ b/ksirc/puke/ppushbt.cpp @@ -6,11 +6,11 @@ PObject * PPushButton::createWidget(CreateArgs &ca) { PPushButton *pb = new PPushButton(ca.parent); - QPushButton *qb; + TQPushButton *qb; if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - qb = new QPushButton((QWidget *) ca.parent->widget()); + qb = new TQPushButton((TQWidget *) ca.parent->widget()); else - qb = new QPushButton(0L); + qb = new TQPushButton(0L); pb->setWidget(qb); pb->setWidgetId(ca.pwI); return pb; @@ -43,15 +43,15 @@ void PPushButton::messageHandler(int fd, PukeMessage *pm) } } -void PPushButton::setWidget(QObject *_qb) +void PPushButton::setWidget(TQObject *_qb) { - if(_qb != 0 && _qb->inherits("QPushButton") == FALSE) + if(_qb != 0 && _qb->inherits("TQPushButton") == FALSE) { errorInvalidSet(_qb); return; } - button = (QPushButton *) _qb; + button = (TQPushButton *) _qb; if(_qb != 0){ } PButton::setWidget(_qb); @@ -59,7 +59,7 @@ void PPushButton::setWidget(QObject *_qb) } -QPushButton *PPushButton::widget() +TQPushButton *PPushButton::widget() { return button; } diff --git a/ksirc/puke/ppushbt.h b/ksirc/puke/ppushbt.h index 87336679..fd624a24 100644 --- a/ksirc/puke/ppushbt.h +++ b/ksirc/puke/ppushbt.h @@ -3,7 +3,7 @@ class PPushButton; -#include +#include #include "pmessage.h" #include "pbutton.h" #include "pobject.h" @@ -20,13 +20,13 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_b = 0); - virtual QPushButton *widget(); + virtual void setWidget(TQObject *_b = 0); + virtual TQPushButton *widget(); public slots: private: - QPushButton *button; + TQPushButton *button; }; diff --git a/ksirc/puke/ptabdialog.cpp b/ksirc/puke/ptabdialog.cpp index b0e3ba2c..4099aa0a 100644 --- a/ksirc/puke/ptabdialog.cpp +++ b/ksirc/puke/ptabdialog.cpp @@ -9,24 +9,24 @@ PObject * PTabDialog::createWidget(CreateArgs &ca) { PTabDialog *ptd = new PTabDialog(ca.parent); - QTabDialog *qtd; + TQTabDialog *qtd; // Retreive the border and direction information out of the // carg string - if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("QTabDialog") == TRUE){ - qtd = (QTabDialog *) ca.fetchedObj; + if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("TQTabDialog") == TRUE){ + qtd = (TQTabDialog *) ca.fetchedObj; ptd->setDeleteAble(FALSE); } else if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - qtd = new QTabDialog((QWidget *) ca.parent->widget()); + qtd = new TQTabDialog((TQWidget *) ca.parent->widget()); else - qtd = new QTabDialog(); + qtd = new TQTabDialog(); ptd->setWidget(qtd); ptd->setWidgetId(ca.pwI); ptd->setPukeController(ca.pc); return ptd; } -PTabDialog::PTabDialog(QObject *) +PTabDialog::PTabDialog(TQObject *) : PWidget() { // Connect slots as needed @@ -76,22 +76,22 @@ void PTabDialog::messageHandler(int fd, PukeMessage *pm) } -void PTabDialog::setWidget(QObject *tb) +void PTabDialog::setWidget(TQObject *tb) { - if(tb != 0 && tb->inherits("QTabDialog") == FALSE) + if(tb != 0 && tb->inherits("TQTabDialog") == FALSE) { errorInvalidSet(tb); return; } - tab = (QTabDialog *) tb; + tab = (TQTabDialog *) tb; if(tab != 0){ } PObject::setWidget(tb); } -QTabDialog *PTabDialog::widget() +TQTabDialog *PTabDialog::widget() { // kdDebug(5008) << "PObject widget called" << endl; return tab; diff --git a/ksirc/puke/ptabdialog.h b/ksirc/puke/ptabdialog.h index 6e669074..17132301 100644 --- a/ksirc/puke/ptabdialog.h +++ b/ksirc/puke/ptabdialog.h @@ -3,7 +3,7 @@ class PTabDialog; -#include +#include #include "pmessage.h" #include "pwidget.h" @@ -13,7 +13,7 @@ class PTabDialog : public PWidget public: static PObject *createWidget(CreateArgs &ca); - PTabDialog(QObject *parent = 0); + PTabDialog(TQObject *parent = 0); virtual ~PTabDialog(); /** @@ -25,16 +25,16 @@ public: /** * Sets the current opbect */ - virtual void setWidget(QObject *tb); + virtual void setWidget(TQObject *tb); /** * Returns the current object */ - virtual QTabDialog *widget(); + virtual TQTabDialog *widget(); private: - QTabDialog *tab; + TQTabDialog *tab; }; diff --git a/ksirc/puke/ptablevw.cpp b/ksirc/puke/ptablevw.cpp index 1dba614b..7c744ac9 100644 --- a/ksirc/puke/ptablevw.cpp +++ b/ksirc/puke/ptablevw.cpp @@ -50,15 +50,15 @@ void PTableView::messageHandler(int fd, PukeMessage *pm) } } -void PTableView::setWidget(QObject *_tbv) +void PTableView::setWidget(TQObject *_tbv) { - if(_tbv != 0 && _tbv->inherits("QGridView") == FALSE) + if(_tbv != 0 && _tbv->inherits("TQGridView") == FALSE) { errorInvalidSet(_tbv); return; } - tbl = (QGridView *) _tbv; + tbl = (TQGridView *) _tbv; if(tbl != 0){ } PFrame::setWidget(_tbv); @@ -66,7 +66,7 @@ void PTableView::setWidget(QObject *_tbv) } -QGridView *PTableView::widget() +TQGridView *PTableView::widget() { return tbl; } diff --git a/ksirc/puke/ptablevw.h b/ksirc/puke/ptablevw.h index 33ba4015..c1043a4b 100644 --- a/ksirc/puke/ptablevw.h +++ b/ksirc/puke/ptablevw.h @@ -3,7 +3,7 @@ class PTableView; -#include +#include #include "pmessage.h" #include "pframe.h" @@ -21,13 +21,13 @@ public: virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *_tbl); - virtual QGridView *widget(); + virtual void setWidget(TQObject *_tbl); + virtual TQGridView *widget(); public slots: private: - QGridView *tbl; + TQGridView *tbl; }; #endif diff --git a/ksirc/puke/pwidget.cpp b/ksirc/puke/pwidget.cpp index d254832b..9ce99a2b 100644 --- a/ksirc/puke/pwidget.cpp +++ b/ksirc/puke/pwidget.cpp @@ -6,7 +6,7 @@ #include #include -#include +#include PWidget::PWidget(PObject *) : PObject() @@ -54,15 +54,15 @@ PWidget::~PWidget() PObject *PWidget::createWidget(CreateArgs &ca) { PWidget *pw = new PWidget(); - QWidget *tw; - if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("QWidget") == TRUE){ - tw = (QWidget *) ca.fetchedObj; + TQWidget *tw; + if(ca.fetchedObj != 0 && ca.fetchedObj->inherits("TQWidget") == TRUE){ + tw = (TQWidget *) ca.fetchedObj; pw->setDeleteAble(FALSE); } else if(ca.parent != 0 && ca.parent->widget()->isWidgetType() == TRUE) - tw = new QWidget((QWidget *) ca.parent->widget()); + tw = new TQWidget((TQWidget *) ca.parent->widget()); else - tw = new QWidget(); + tw = new TQWidget(); pw->setWidget(tw); pw->setWidgetId(ca.pwI); pw->setPukeController(ca.pc); @@ -175,7 +175,7 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) { pmRet.cArg = new char[15]; pmRet.iTextSize = 15; - QColor back = widget()->backgroundColor(); + TQColor back = widget()->backgroundColor(); sprintf(pmRet.cArg, "%d,%d,%d", back.red(), back.green(), back.blue()); pmRet.iCommand = -pm->iCommand; @@ -186,7 +186,7 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) break; } case PUKE_WIDGET_SET_BACKGROUND_PIXMAP: - widget()->setBackgroundPixmap(QPixmap(pm->cArg)); + widget()->setBackgroundPixmap(TQPixmap(pm->cArg)); pmRet.iCommand = -pm->iCommand; pmRet.iWinId = pm->iWinId; @@ -195,7 +195,7 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) emit outputMessage(fd, &pmRet); break; case PUKE_WIDGET_SET_BACKGROUND_MODE: - widget()->setBackgroundMode((QWidget::BackgroundMode) pm->iArg); + widget()->setBackgroundMode((TQWidget::BackgroundMode) pm->iArg); pmRet.iCommand = -pm->iCommand; pmRet.iWinId = pm->iWinId; @@ -208,15 +208,15 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) { int *pos; pos = (int *) pm->cArg; - QColor bg(pos[0], pos[1], pos[2]); - QColorGroup cg = QColorGroup(widget()->colorGroup().foreground(), + TQColor bg(pos[0], pos[1], pos[2]); + TQColorGroup cg = TQColorGroup(widget()->colorGroup().foreground(), bg, widget()->colorGroup().light(), widget()->colorGroup().dark(), widget()->colorGroup().mid(), widget()->colorGroup().text(), bg); - widget()->setPalette(QPalette(cg,cg,cg)); + widget()->setPalette(TQPalette(cg,cg,cg)); pmRet.iCommand = -pm->iCommand; pmRet.iWinId = pm->iWinId; @@ -236,7 +236,7 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) break; case PUKE_WIDGET_RECREATE: { - QWidget *nparent = 0x0; + TQWidget *nparent = 0x0; if(pm->iArg != 0x0){ widgetId wiWidget; wiWidget.fd = fd; @@ -250,7 +250,7 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) qWarning("Recreate: %d %d %d", point_show[0], point_show[1], point_show[3]); - widget()->reparent(nparent, (WFlags) 0, QPoint(point_show[0], point_show[1]), point_show[3]); + widget()->reparent(nparent, (WFlags) 0, TQPoint(point_show[0], point_show[1]), point_show[3]); pmRet.iCommand = PUKE_WIDGET_RECREATE_ACK; pmRet.iWinId = pm->iWinId; @@ -264,29 +264,29 @@ void PWidget::messageHandler(int fd, PukeMessage *pm) } } -void PWidget::setWidget(QObject *_w) +void PWidget::setWidget(TQObject *_w) { - if(_w != 0 && _w->inherits("QWidget") == FALSE) + if(_w != 0 && _w->inherits("TQWidget") == FALSE) { errorInvalidSet(_w); return; } - w = (QWidget *) _w; + w = (TQWidget *) _w; if(w != 0){ widget()->installEventFilter(this); } PObject::setWidget(_w); } -QWidget *PWidget::widget() +TQWidget *PWidget::widget() { // kdDebug(5008) << "PWidget widget called" << endl; return w; } // PWidget specific -bool PWidget::eventFilter(QObject *o, QEvent *e) +bool PWidget::eventFilter(TQObject *o, TQEvent *e) { if(e->type() < 20 && e->type() >= 0){ (this->*(eventList[e->type()]))(o,e); @@ -307,7 +307,7 @@ bool PWidget::eventFilter(QObject *o, QEvent *e) return false; } -void PWidget::eventNone(QObject *, QEvent *e) +void PWidget::eventNone(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; @@ -324,12 +324,12 @@ void PWidget::eventNone(QObject *, QEvent *e) } -void PWidget::eventTimer(QObject *, QEvent *e) +void PWidget::eventTimer(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; - QTimerEvent *et = (QTimerEvent *)(e); + TQTimerEvent *et = (TQTimerEvent *)(e); wI = widgetIden(); pm.iCommand = PUKE_WIDGET_EVENT_TIMER; @@ -341,12 +341,12 @@ void PWidget::eventTimer(QObject *, QEvent *e) } -void PWidget::eventMouse(QObject *, QEvent *e) +void PWidget::eventMouse(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; - QMouseEvent *me = (QMouseEvent *)(e); + TQMouseEvent *me = (TQMouseEvent *)(e); wI = widgetIden(); pm.iCommand = - e->type() - 1020; // 1020 offset for events @@ -368,12 +368,12 @@ void PWidget::eventMouse(QObject *, QEvent *e) } -void PWidget::eventKey(QObject *, QEvent *e) +void PWidget::eventKey(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; - QKeyEvent *ke = (QKeyEvent *)(e); + TQKeyEvent *ke = (TQKeyEvent *)(e); wI = widgetIden(); pm.iCommand = - e->type() - 1020; // 1020 offset for events @@ -394,14 +394,14 @@ void PWidget::eventKey(QObject *, QEvent *e) } -void PWidget::eventFocus(QObject *, QEvent *e) +void PWidget::eventFocus(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; // kdDebug(5008) << "PWidget: eventFocus" << endl; - QFocusEvent *fe = (QFocusEvent *)(e); + TQFocusEvent *fe = (TQFocusEvent *)(e); wI = widgetIden(); pm.iCommand = - e->type() - 1020; // 1020 offset for events @@ -418,7 +418,7 @@ void PWidget::eventFocus(QObject *, QEvent *e) delete[] pm.cArg; } -void PWidget::eventPaint(QObject *, QEvent *e) +void PWidget::eventPaint(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; @@ -433,12 +433,12 @@ void PWidget::eventPaint(QObject *, QEvent *e) } -void PWidget::eventMove(QObject *, QEvent *e) +void PWidget::eventMove(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; - QMoveEvent *me = (QMoveEvent *)(e); + TQMoveEvent *me = (TQMoveEvent *)(e); wI = widgetIden(); pm.iCommand = - e->type() - 1020; // 1020 offset for events @@ -460,12 +460,12 @@ void PWidget::eventMove(QObject *, QEvent *e) } -void PWidget::eventResize(QObject *, QEvent *e) +void PWidget::eventResize(TQObject *, TQEvent *e) { PukeMessage pm; widgetId wI; - QResizeEvent *re = (QResizeEvent *)(e); + TQResizeEvent *re = (TQResizeEvent *)(e); wI = widgetIden(); pm.iCommand = - e->type() - 1020; // 1020 offset for events diff --git a/ksirc/puke/pwidget.h b/ksirc/puke/pwidget.h index f7f748fb..68853e63 100644 --- a/ksirc/puke/pwidget.h +++ b/ksirc/puke/pwidget.h @@ -3,8 +3,8 @@ class PWidget; -#include -#include +#include +#include #include "pobject.h" #include "pmessage.h" @@ -20,25 +20,25 @@ class PWidget : public PObject virtual void messageHandler(int fd, PukeMessage *pm); - virtual void setWidget(QObject *w = 0x0); - virtual QWidget *widget(); + virtual void setWidget(TQObject *w = 0x0); + virtual TQWidget *widget(); protected: - bool eventFilter(QObject *o, QEvent *e); + bool eventFilter(TQObject *o, TQEvent *e); private: - QWidget *w; - - void (PWidget::*eventList[20])(QObject *, QEvent *); - - void eventNone(QObject *, QEvent *); - void eventTimer(QObject *, QEvent *); - void eventMouse(QObject *, QEvent *); - void eventKey(QObject *, QEvent *); - void eventFocus(QObject *, QEvent *); - void eventPaint(QObject *, QEvent *); - void eventMove(QObject *, QEvent *); - void eventResize(QObject *, QEvent *); + TQWidget *w; + + void (PWidget::*eventList[20])(TQObject *, TQEvent *); + + void eventNone(TQObject *, TQEvent *); + void eventTimer(TQObject *, TQEvent *); + void eventMouse(TQObject *, TQEvent *); + void eventKey(TQObject *, TQEvent *); + void eventFocus(TQObject *, TQEvent *); + void eventPaint(TQObject *, TQEvent *); + void eventMove(TQObject *, TQEvent *); + void eventResize(TQObject *, TQEvent *); }; -- cgit v1.2.1