summaryrefslogtreecommitdiffstats
path: root/kopete/protocols/winpopup
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2010-07-31 19:48:06 +0000
commit47c8a359c5276062c4bc17f0e82410f29081b502 (patch)
tree2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /kopete/protocols/winpopup
parent6f82532777a35e0e60bbd2b290b2e93e646f349b (diff)
downloadtdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.tar.gz
tdenetwork-47c8a359c5276062c4bc17f0e82410f29081b502.zip
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1157648 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kopete/protocols/winpopup')
-rw-r--r--kopete/protocols/winpopup/libwinpopup/libwinpopup.cpp106
-rw-r--r--kopete/protocols/winpopup/libwinpopup/libwinpopup.h46
-rw-r--r--kopete/protocols/winpopup/wpaccount.cpp34
-rw-r--r--kopete/protocols/winpopup/wpaccount.h26
-rw-r--r--kopete/protocols/winpopup/wpaddcontact.cpp30
-rw-r--r--kopete/protocols/winpopup/wpaddcontact.h4
-rw-r--r--kopete/protocols/winpopup/wpcontact.cpp30
-rw-r--r--kopete/protocols/winpopup/wpcontact.h20
-rw-r--r--kopete/protocols/winpopup/wpeditaccount.cpp12
-rw-r--r--kopete/protocols/winpopup/wpeditaccount.h2
-rw-r--r--kopete/protocols/winpopup/wpprotocol.cpp42
-rw-r--r--kopete/protocols/winpopup/wpprotocol.h28
-rw-r--r--kopete/protocols/winpopup/wpuserinfo.cpp20
-rw-r--r--kopete/protocols/winpopup/wpuserinfo.h6
14 files changed, 203 insertions, 203 deletions
diff --git a/kopete/protocols/winpopup/libwinpopup/libwinpopup.cpp b/kopete/protocols/winpopup/libwinpopup/libwinpopup.cpp
index d26e461c..9bdbee27 100644
--- a/kopete/protocols/winpopup/libwinpopup/libwinpopup.cpp
+++ b/kopete/protocols/winpopup/libwinpopup/libwinpopup.cpp
@@ -16,9 +16,9 @@
***************************************************************************/
// QT Includes
-#include <qdir.h>
-#include <qfileinfo.h>
-#include <qregexp.h>
+#include <tqdir.h>
+#include <tqfileinfo.h>
+#include <tqregexp.h>
// KDE Includes
#include <kapplication.h>
@@ -33,13 +33,13 @@
// Local Includes
#include "libwinpopup.h"
-WinPopupLib::WinPopupLib(const QString &smbClient,int groupFreq)
+WinPopupLib::WinPopupLib(const TQString &smbClient,int groupFreq)
: smbClientBin(smbClient), groupCheckFreq(groupFreq)
{
- connect(&updateGroupDataTimer, SIGNAL(timeout()), this, SLOT(slotUpdateGroupData()));
+ connect(&updateGroupDataTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotUpdateGroupData()));
updateGroupDataTimer.start(1, true);
- QTimer::singleShot(1, this, SLOT(slotStartDirLister()));
+ TQTimer::singleShot(1, this, TQT_SLOT(slotStartDirLister()));
}
WinPopupLib::~WinPopupLib()
@@ -51,8 +51,8 @@ void WinPopupLib::slotStartDirLister()
if (checkMessageDir()) {
dirLister = new KDirLister();
dirLister->setAutoUpdate(true);
- connect(dirLister, SIGNAL(newItems(const KFileItemList &)), this, SLOT(slotNewMessages(const KFileItemList &)));
- connect(dirLister, SIGNAL(completed()), this, SLOT(slotListCompleted()));
+ connect(dirLister, TQT_SIGNAL(newItems(const KFileItemList &)), this, TQT_SLOT(slotNewMessages(const KFileItemList &)));
+ connect(dirLister, TQT_SIGNAL(completed()), this, TQT_SLOT(slotListCompleted()));
dirLister->openURL(KURL::fromPathOrURL(WP_POPUP_DIR));
}
}
@@ -60,11 +60,11 @@ void WinPopupLib::slotStartDirLister()
/**
* return the group list
*/
-const QStringList WinPopupLib::getGroups()
+const TQStringList WinPopupLib::getGroups()
{
- QStringList ret;
- QMap<QString, WorkGroup>::ConstIterator end = theGroups.end();
- for(QMap<QString, WorkGroup>::ConstIterator i = theGroups.begin(); i != end; i++)
+ TQStringList ret;
+ TQMap<TQString, WorkGroup>::ConstIterator end = theGroups.end();
+ for(TQMap<TQString, WorkGroup>::ConstIterator i = theGroups.begin(); i != end; i++)
ret += i.key();
return ret;
@@ -73,7 +73,7 @@ const QStringList WinPopupLib::getGroups()
/**
* return the host list
*/
-const QStringList WinPopupLib::getHosts(const QString &Group)
+const TQStringList WinPopupLib::getHosts(const TQString &Group)
{
return theGroups[Group].Hosts();
}
@@ -81,13 +81,13 @@ const QStringList WinPopupLib::getHosts(const QString &Group)
/**
* return if a host is in the host list
*/
-bool WinPopupLib::checkHost(const QString &Name)
+bool WinPopupLib::checkHost(const TQString &Name)
{
// kdDebug() << "WP checkHost: " << Name << endl;
bool ret = false;
- QMap<QString, WorkGroup>::Iterator end = theGroups.end();
- for(QMap<QString, WorkGroup>::Iterator i = theGroups.begin(); i != end && !ret; i++) {
+ TQMap<TQString, WorkGroup>::Iterator end = theGroups.end();
+ for(TQMap<TQString, WorkGroup>::Iterator i = theGroups.begin(); i != end && !ret; i++) {
if ((*i).Hosts().contains(Name.upper())) {
ret = true;
break;
@@ -100,7 +100,7 @@ bool WinPopupLib::checkHost(const QString &Name)
bool WinPopupLib::checkMessageDir()
{
- QDir dir(WP_POPUP_DIR);
+ TQDir dir(WP_POPUP_DIR);
if (! dir.exists()) {
int tmpYesNo = KMessageBox::warningYesNo(Kopete::UI::Global::mainWidget(),
i18n("Working directory %1 does not exist.\n"
@@ -108,9 +108,9 @@ bool WinPopupLib::checkMessageDir()
"Install Into Samba (Configure... -> Account -> Edit) information\n"
"on how to do this.\n"
"Should the directory be created? (May need root password)").arg(WP_POPUP_DIR),
- QString::fromLatin1("Winpopup"), i18n("Create Directory"), i18n("Do Not Create"));
+ TQString::fromLatin1("Winpopup"), i18n("Create Directory"), i18n("Do Not Create"));
if (tmpYesNo == KMessageBox::Yes) {
- QStringList kdesuArgs = QStringList(QString("-c mkdir -p -m 0777 " + WP_POPUP_DIR));
+ TQStringList kdesuArgs = TQStringList(TQString("-c mkdir -p -m 0777 " + WP_POPUP_DIR));
if (KApplication::kdeinitExecWait("kdesu", kdesuArgs) == 0) return true;
}
} else {
@@ -127,9 +127,9 @@ bool WinPopupLib::checkMessageDir()
"You will not receive messages if you say no.\n"
"You can also correct it manually (chmod 0777 %1) and restart kopete.\n"
"Fix? (May need root password)").arg(WP_POPUP_DIR),
- QString::fromLatin1("Winpopup"), i18n("Fix"), i18n("Do Not Fix"));
+ TQString::fromLatin1("Winpopup"), i18n("Fix"), i18n("Do Not Fix"));
if (tmpYesNo == KMessageBox::Yes) {
- QStringList kdesuArgs = QStringList(QString("-c chmod 0777 " + WP_POPUP_DIR));
+ TQStringList kdesuArgs = TQStringList(TQString("-c chmod 0777 " + WP_POPUP_DIR));
if (KApplication::kdeinitExecWait("kdesu", kdesuArgs) == 0) return true;
}
} else {
@@ -148,22 +148,22 @@ void WinPopupLib::slotUpdateGroupData()
passedInitialHost = false;
todo.clear();
currentGroupsMap.clear();
- currentHost = QString::fromLatin1("LOCALHOST");
+ currentHost = TQString::fromLatin1("LOCALHOST");
startReadProcess(currentHost);
}
-void WinPopupLib::startReadProcess(const QString &Host)
+void WinPopupLib::startReadProcess(const TQString &Host)
{
currentHosts.clear();
currentGroups.clear();
- currentGroup = QString();
+ currentGroup = TQString();
// for Samba 3
KProcIO *reader = new KProcIO;
*reader << smbClientBin << "-N" << "-E" << "-g" << "-L" << Host << "-";
- connect(reader, SIGNAL(readReady(KProcIO *)), this, SLOT(slotReadProcessReady(KProcIO *)));
- connect(reader, SIGNAL(processExited(KProcess *)), this, SLOT(slotReadProcessExited(KProcess *)));
+ connect(reader, TQT_SIGNAL(readReady(KProcIO *)), this, TQT_SLOT(slotReadProcessReady(KProcIO *)));
+ connect(reader, TQT_SIGNAL(processExited(KProcess *)), this, TQT_SLOT(slotReadProcessExited(KProcess *)));
if (!reader->start(KProcess::NotifyOnExit, true)) {
// still to come
@@ -173,8 +173,8 @@ void WinPopupLib::startReadProcess(const QString &Host)
void WinPopupLib::slotReadProcessReady(KProcIO *r)
{
- QString tmpLine = QString::null;
- QRegExp group("^Workgroup\\|(.*)\\|(.*)$"), host("^Server\\|(.*)\\|(.*)$"),
+ TQString tmpLine = TQString::null;
+ TQRegExp group("^Workgroup\\|(.*)\\|(.*)$"), host("^Server\\|(.*)\\|(.*)$"),
info("^Domain=\\[([^\\]]+)\\] OS=\\[([^\\]]+)\\] Server=\\[([^\\]]+)\\]"),
error("Connection.*failed");
@@ -184,7 +184,7 @@ void WinPopupLib::slotReadProcessReady(KProcIO *r)
if (group.search(tmpLine) != -1) currentGroups[group.cap(1)] = group.cap(2);
if (error.search(tmpLine) != -1) {
kdDebug(14170) << "Connection to " << currentHost << " failed!" << endl;
- if (currentHost == QString::fromLatin1("LOCALHOST")) currentHost = QString::fromLatin1("failed"); // to be sure
+ if (currentHost == TQString::fromLatin1("LOCALHOST")) currentHost = TQString::fromLatin1("failed"); // to be sure
}
}
}
@@ -203,11 +203,11 @@ void WinPopupLib::slotReadProcessExited(KProcess *r)
done += currentHost;
if (!currentGroups.isEmpty()) {
- QMap<QString, WorkGroup> newGroups;
+ TQMap<TQString, WorkGroup> newGroups;
//loop through the read groups and check for new ones
- QMap<QString, QString>::ConstIterator end = currentGroups.end();
- for (QMap<QString, QString>::ConstIterator i = currentGroups.begin(); i != end; i++) {
- QString groupMaster = i.data();
+ TQMap<TQString, TQString>::ConstIterator end = currentGroups.end();
+ for (TQMap<TQString, TQString>::ConstIterator i = currentGroups.begin(); i != end; i++) {
+ TQString groupMaster = i.data();
if (!done.contains(groupMaster)) todo += groupMaster;
}
}
@@ -223,17 +223,17 @@ void WinPopupLib::slotReadProcessExited(KProcess *r)
} else {
passedInitialHost = true;
if (!currentGroups.isEmpty()) {
- QMap<QString, QString>::ConstIterator end = currentGroups.end();
- for (QMap<QString, QString>::ConstIterator i = currentGroups.begin(); i != end; i++) {
- QString groupMaster = i.data();
+ TQMap<TQString, TQString>::ConstIterator end = currentGroups.end();
+ for (TQMap<TQString, TQString>::ConstIterator i = currentGroups.begin(); i != end; i++) {
+ TQString groupMaster = i.data();
todo += groupMaster;
}
} else {
- if (currentHost == QString::fromLatin1("failed"))
+ if (currentHost == TQString::fromLatin1("failed"))
KMessageBox::error(Kopete::UI::Global::mainWidget(),
i18n("Connection to localhost failed!\n"
"Is your samba server running?"),
- QString::fromLatin1("Winpopup"));
+ TQString::fromLatin1("Winpopup"));
}
}
@@ -250,7 +250,7 @@ void WinPopupLib::slotReadProcessExited(KProcess *r)
void WinPopupLib::slotListCompleted()
{
/// only to check received messages during start up, then we use newItems. GF
- disconnect(dirLister, SIGNAL(completed()), this, SLOT(slotListCompleted()));
+ disconnect(dirLister, TQT_SIGNAL(completed()), this, TQT_SLOT(slotListCompleted()));
readMessages(dirLister->items());
}
@@ -264,25 +264,25 @@ void WinPopupLib::slotNewMessages(const KFileItemList &items)
*/
void WinPopupLib::readMessages(const KFileItemList &items)
{
- QPtrListIterator<KFileItem> it(items);
+ TQPtrListIterator<KFileItem> it(items);
KFileItem *tmpItem;
while ((tmpItem = it.current()) != 0) {
if (tmpItem->isFile()) {
- QFile messageFile(tmpItem->url().path());
+ TQFile messageFile(tmpItem->url().path());
if (messageFile.open(IO_ReadOnly)) {
- QTextStream stream(&messageFile);
- QString sender;
- QDateTime time;
- QString text;
+ TQTextStream stream(&messageFile);
+ TQString sender;
+ TQDateTime time;
+ TQString text;
// first line is sender, can this really be empty? GF
sender = stream.readLine();
sender = sender.upper();
// second line is time
- QString tmpTime = stream.readLine();
- time = QDateTime::fromString(tmpTime, Qt::ISODate);
+ TQString tmpTime = stream.readLine();
+ time = TQDateTime::fromString(tmpTime, Qt::ISODate);
while (!stream.atEnd()) {
text.append(stream.readLine());
@@ -296,16 +296,16 @@ void WinPopupLib::readMessages(const KFileItemList &items)
// delete file
if (!messageFile.remove()) {
- // QFile::remove() seems to be very persistent, it removes even files with 0444 owned by root
+ // TQFile::remove() seems to be very persistent, it removes even files with 0444 owned by root
// if the directory permissions are 0777 - so this is just for safety. GF
kdDebug(14170) << "Message file not removed - how that?" << endl;
int tmpYesNo = KMessageBox::warningYesNo(Kopete::UI::Global::mainWidget(),
i18n("A message file could not be removed; "
"maybe the permissions are wrong.\n"
"Fix? (May need root password)"),
- QString::fromLatin1("Winpopup"), i18n("Fix"), i18n("Do Not Fix"));
+ TQString::fromLatin1("Winpopup"), i18n("Fix"), i18n("Do Not Fix"));
if (tmpYesNo == KMessageBox::Yes) {
- QStringList kdesuArgs = QStringList(QString("-c chmod 0666 " + tmpItem->url().path()));
+ TQStringList kdesuArgs = TQStringList(TQString("-c chmod 0666 " + tmpItem->url().path()));
if (KApplication::kdeinitExecWait("kdesu", kdesuArgs) == 0) {
if (!messageFile.remove())
KMessageBox::error(Kopete::UI::Global::mainWidget(), i18n("Still cannot remove it; please fix manually."));
@@ -325,13 +325,13 @@ void WinPopupLib::readMessages(const KFileItemList &items)
/**
* send a message
*/
-void WinPopupLib::sendMessage(const QString &Body, const QString &Destination)
+void WinPopupLib::sendMessage(const TQString &Body, const TQString &Destination)
{
KProcess *sender = new KProcess(this);
*sender << smbClientBin << "-M" << Destination;
*sender << "-N" << "-";
- connect(sender, SIGNAL(processExited(KProcess *)), this, SLOT(slotSendProcessExited(KProcess *)));
+ connect(sender, TQT_SIGNAL(processExited(KProcess *)), this, TQT_SLOT(slotSendProcessExited(KProcess *)));
if (sender->start(KProcess::NotifyOnExit, KProcess::Stdin)) {
sender->writeStdin(Body.local8Bit(), Body.local8Bit().length());
@@ -349,7 +349,7 @@ void WinPopupLib::slotSendProcessExited(KProcess *p)
delete p;
}
-void WinPopupLib::settingsChanged(const QString &smbClient, int groupFreq)
+void WinPopupLib::settingsChanged(const TQString &smbClient, int groupFreq)
{
smbClientBin = smbClient;
groupCheckFreq = groupFreq;
diff --git a/kopete/protocols/winpopup/libwinpopup/libwinpopup.h b/kopete/protocols/winpopup/libwinpopup/libwinpopup.h
index 77f8b8a6..0e594932 100644
--- a/kopete/protocols/winpopup/libwinpopup/libwinpopup.h
+++ b/kopete/protocols/winpopup/libwinpopup/libwinpopup.h
@@ -19,29 +19,29 @@
#define LIBWINPOPUP_H
//QT includes
-#include <qobject.h>
-#include <qmap.h>
-#include <qstringlist.h>
-#include <qtimer.h>
-#include <qdatetime.h>
+#include <tqobject.h>
+#include <tqmap.h>
+#include <tqstringlist.h>
+#include <tqtimer.h>
+#include <tqdatetime.h>
// KDE Includes
#include <kprocio.h>
#include <kfileitem.h>
-const QString WP_POPUP_DIR = QString::fromLatin1("/var/lib/winpopup");
+const TQString WP_POPUP_DIR = TQString::fromLatin1("/var/lib/winpopup");
class KDirLister;
-typedef QMap<QString, QString> stringMap;
+typedef TQMap<TQString, TQString> stringMap;
class WorkGroup
{
- QStringList groupHosts;
+ TQStringList groupHosts;
public:
- const QStringList &Hosts() { return groupHosts; }
- void addHosts(const QStringList &newHosts) { groupHosts = newHosts; }
+ const TQStringList &Hosts() { return groupHosts; }
+ void addHosts(const TQStringList &newHosts) { groupHosts = newHosts; }
};
class WinPopupLib : public QObject
@@ -49,23 +49,23 @@ class WinPopupLib : public QObject
Q_OBJECT
public:
- WinPopupLib(const QString &smbClient,int groupFreq);
+ WinPopupLib(const TQString &smbClient,int groupFreq);
~WinPopupLib();
- const QStringList getGroups();
- const QStringList getHosts(const QString &Group);
- bool checkHost(const QString &Name);
- void settingsChanged(const QString &smbClient, int groupFreq);
- void sendMessage(const QString &Body, const QString &Destination);
+ const TQStringList getGroups();
+ const TQStringList getHosts(const TQString &Group);
+ bool checkHost(const TQString &Name);
+ void settingsChanged(const TQString &smbClient, int groupFreq);
+ void sendMessage(const TQString &Body, const TQString &Destination);
private:
bool passedInitialHost;
- QMap<QString, WorkGroup> theGroups, currentGroupsMap;
- QString currentGroup, currentHost;
- QStringList todo, done, currentHosts;
+ TQMap<TQString, WorkGroup> theGroups, currentGroupsMap;
+ TQString currentGroup, currentHost;
+ TQStringList todo, done, currentHosts;
stringMap currentGroups;
- QTimer updateGroupDataTimer;
- QString smbClientBin;
+ TQTimer updateGroupDataTimer;
+ TQString smbClientBin;
int groupCheckFreq;
KDirLister *dirLister;
@@ -74,7 +74,7 @@ private:
private slots:
void slotUpdateGroupData();
- void startReadProcess(const QString &Host);
+ void startReadProcess(const TQString &Host);
void slotReadProcessReady(KProcIO *r);
void slotReadProcessExited(KProcess *r);
void slotSendProcessExited(KProcess *p);
@@ -83,7 +83,7 @@ private slots:
void slotNewMessages(const KFileItemList &items);
signals:
- void signalNewMessage(const QString &, const QDateTime &, const QString &);
+ void signalNewMessage(const TQString &, const TQDateTime &, const TQString &);
};
#endif
diff --git a/kopete/protocols/winpopup/wpaccount.cpp b/kopete/protocols/winpopup/wpaccount.cpp
index 4b1342ff..d7439628 100644
--- a/kopete/protocols/winpopup/wpaccount.cpp
+++ b/kopete/protocols/winpopup/wpaccount.cpp
@@ -19,7 +19,7 @@
***************************************************************************/
// QT Includes
-#include <qregexp.h>
+#include <tqregexp.h>
// KDE Includes
#include <kdebug.h>
@@ -34,7 +34,7 @@
class KPopupMenu;
-WPAccount::WPAccount(WPProtocol *parent, const QString &accountID, const char *name)
+WPAccount::WPAccount(WPProtocol *parent, const TQString &accountID, const char *name)
: Kopete::Account(parent, accountID, name)
{
// kdDebug(14170) << "WPAccount::WPAccount()" << endl;
@@ -53,20 +53,20 @@ WPAccount::~WPAccount()
{
}
-const QStringList WPAccount::getGroups()
+const TQStringList WPAccount::getGroups()
{
return mProtocol->getGroups();
}
-const QStringList WPAccount::getHosts(const QString &Group)
+const TQStringList WPAccount::getHosts(const TQString &Group)
{
return mProtocol->getHosts(Group);
}
-bool WPAccount::checkHost(const QString &Name)
+bool WPAccount::checkHost(const TQString &Name)
{
// kdDebug() << "WPAccount::checkHost: " << Name << endl;
- if (Name.upper() == QString::fromLatin1("LOCALHOST")) {
+ if (Name.upper() == TQString::fromLatin1("LOCALHOST")) {
// Assume localhost is always there, but it will not appear in the samba output.
// Should never happen as localhost is now forbidden as contact, just for safety. GF
return true;
@@ -75,7 +75,7 @@ bool WPAccount::checkHost(const QString &Name)
}
}
-bool WPAccount::createContact(const QString &contactId, Kopete::MetaContact *parentContact )
+bool WPAccount::createContact(const TQString &contactId, Kopete::MetaContact *parentContact )
{
// kdDebug(14170) << "[WPAccount::createContact] contactId: " << contactId << endl;
@@ -89,7 +89,7 @@ bool WPAccount::createContact(const QString &contactId, Kopete::MetaContact *par
return false;
}
-void WPAccount::slotGotNewMessage(const QString &Body, const QDateTime &Arrival, const QString &From)
+void WPAccount::slotGotNewMessage(const TQString &Body, const TQDateTime &Arrival, const TQString &From)
{
// kdDebug(14170) << "WPAccount::slotGotNewMessage(" << Body << ", " << Arrival.toString() << ", " << From << ")" << endl;
@@ -97,7 +97,7 @@ void WPAccount::slotGotNewMessage(const QString &Body, const QDateTime &Arrival,
// IPs can not be matched to an account anyway.
// This should happen rarely but they make kopete crash.
// The reason for this seems to be in ChatSessionManager? GF
- QRegExp ip("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}");
+ TQRegExp ip("\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}");
// kdDebug(14170) << "ip.search: " << From << " match: " << ip.search(From) << endl;
@@ -142,7 +142,7 @@ void WPAccount::updateAccountId()
myself() = new WPContact(this, accountId(), accountId(), 0);
}*/
-void WPAccount::setAway(bool status, const QString &awayMessage)
+void WPAccount::setAway(bool status, const TQString &awayMessage)
{
// kdDebug(14170) << "WPAccount::setAway()" << endl;
@@ -164,13 +164,13 @@ KActionMenu* WPAccount::actionMenu()
if (mProtocol)
{
- KAction *goOnline = new KAction("Online", QIconSet(mProtocol->WPOnline.iconFor(this)), 0,
- this, SLOT(connect()), theActionMenu, "actionGoAvailable");
+ KAction *goOnline = new KAction("Online", TQIconSet(mProtocol->WPOnline.iconFor(this)), 0,
+ this, TQT_SLOT(connect()), theActionMenu, "actionGoAvailable");
goOnline->setEnabled(isConnected() && isAway());
theActionMenu->insert(goOnline);
- KAction *goAway = new KAction("Away", QIconSet(mProtocol->WPAway.iconFor(this)), 0,
- this, SLOT(goAway()), theActionMenu, "actionGoAway");
+ KAction *goAway = new KAction("Away", TQIconSet(mProtocol->WPAway.iconFor(this)), 0,
+ this, TQT_SLOT(goAway()), theActionMenu, "actionGoAway");
goAway->setEnabled(isConnected() && !isAway());
theActionMenu->insert(goAway);
@@ -178,14 +178,14 @@ KActionMenu* WPAccount::actionMenu()
theActionMenu->popupMenu()->insertSeparator();
theActionMenu->insert(new KAction(i18n("Properties"), 0,
- this, SLOT(editAccount()), theActionMenu, "actionAccountProperties"));
+ this, TQT_SLOT(editAccount()), theActionMenu, "actionAccountProperties"));
}
return theActionMenu;
}
-void WPAccount::slotSendMessage(const QString &Body, const QString &Destination)
+void WPAccount::slotSendMessage(const TQString &Body, const TQString &Destination)
{
kdDebug(14170) << "WPAccount::slotSendMessage(" << Body << ", " << Destination << ")" << endl;
@@ -193,7 +193,7 @@ void WPAccount::slotSendMessage(const QString &Body, const QString &Destination)
mProtocol->sendMessage(Body, Destination);
}
-void WPAccount::setOnlineStatus(const Kopete::OnlineStatus &status, const QString &reason)
+void WPAccount::setOnlineStatus(const Kopete::OnlineStatus &status, const TQString &reason)
{
if (myself()->onlineStatus().status() == Kopete::OnlineStatus::Offline && status.status() == Kopete::OnlineStatus::Online)
connect( status );
diff --git a/kopete/protocols/winpopup/wpaccount.h b/kopete/protocols/winpopup/wpaccount.h
index f916ca86..ae3744de 100644
--- a/kopete/protocols/winpopup/wpaccount.h
+++ b/kopete/protocols/winpopup/wpaccount.h
@@ -23,7 +23,7 @@
// QT Includes
-#include <qpixmap.h>
+#include <tqpixmap.h>
// KDE Includes
@@ -51,54 +51,54 @@ class WPAccount : public Kopete::Account
// Kopete::Account overloading
public:
- WPAccount(WPProtocol *parent, const QString& accountID, const char *name = 0);
+ WPAccount(WPProtocol *parent, const TQString& accountID, const char *name = 0);
~WPAccount();
virtual KActionMenu* actionMenu(); // Per-protocol actions for the systray and the status bar
- virtual void setAway(bool status, const QString &); // Set user away
+ virtual void setAway(bool status, const TQString &); // Set user away
public slots:
virtual void connect(const Kopete::OnlineStatus &); // Connect to server
virtual void disconnect(); // Disconnect from server
- void goAvailable() { setAway(false, QString::null); } // Two convenience slots
- void goAway() { setAway(true, QString::null); } // for available and away
+ void goAvailable() { setAway(false, TQString::null); } // Two convenience slots
+ void goAway() { setAway(true, TQString::null); } // for available and away
// Stuff used internally & by colleague classes
public:
- const QStringList getGroups();
- const QStringList getHosts(const QString &Group);
+ const TQStringList getGroups();
+ const TQStringList getHosts(const TQString &Group);
// Stuff used by WPContact
public:
/**
* Returns whether or not the named host is online.
*/
- bool checkHost(const QString &Name);
+ bool checkHost(const TQString &Name);
public slots:
/**
* Dispatches said message to the destination.
*/
- void slotSendMessage(const QString &Body, const QString &Destination);
+ void slotSendMessage(const TQString &Body, const TQString &Destination);
/**
* Called when a new message arrives with the message's data.
*/
- void slotGotNewMessage(const QString &Body, const QDateTime &Arrival, const QString &From);
+ void slotGotNewMessage(const TQString &Body, const TQDateTime &Arrival, const TQString &From);
/* Reimplemented from Kopete::Account */
- void setOnlineStatus( const Kopete::OnlineStatus &status , const QString &reason = QString::null);
+ void setOnlineStatus( const Kopete::OnlineStatus &status , const TQString &reason = TQString::null);
protected:
- virtual bool createContact(const QString &contactId, Kopete::MetaContact *parentContact);
+ virtual bool createContact(const TQString &contactId, Kopete::MetaContact *parentContact);
private slots:
// void updateAccountId();
private:
WPProtocol *mProtocol;
- QString theAwayMessage; // The message to give when the user is away
+ TQString theAwayMessage; // The message to give when the user is away
};
#endif
diff --git a/kopete/protocols/winpopup/wpaddcontact.cpp b/kopete/protocols/winpopup/wpaddcontact.cpp
index 6187c644..e5912c14 100644
--- a/kopete/protocols/winpopup/wpaddcontact.cpp
+++ b/kopete/protocols/winpopup/wpaddcontact.cpp
@@ -18,7 +18,7 @@
* *
***************************************************************************/
// QT Includes
-#include <qlayout.h>
+#include <tqlayout.h>
// KDE Includes
#include <kcombobox.h>
@@ -36,14 +36,14 @@
#include "wpaccount.h"
#include "wpaddcontact.h"
-WPAddContact::WPAddContact(QWidget *parent, WPAccount *newAccount, const char *name) : AddContactPage(parent, name)
+WPAddContact::WPAddContact(TQWidget *parent, WPAccount *newAccount, const char *name) : AddContactPage(parent, name)
{
// kdDebug(14170) << "WPAddContact::WPAddContact(<owner>, " << newAccount << ", <parent>, " << name << ")" << endl;
- (new QVBoxLayout(this))->setAutoAdd(true);
+ (new TQVBoxLayout(this))->setAutoAdd(true);
theDialog = new WPAddContactBase(this);
- connect(theDialog->mHostGroup, SIGNAL(activated(const QString &)), this, SLOT(slotSelected(const QString &)));
- connect(theDialog->mRefresh, SIGNAL(clicked()), this, SLOT(slotUpdateGroups()));
+ connect(theDialog->mHostGroup, TQT_SIGNAL(activated(const TQString &)), this, TQT_SLOT(slotSelected(const TQString &)));
+ connect(theDialog->mRefresh, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotUpdateGroups()));
theDialog->show();
theAccount = newAccount;
@@ -61,22 +61,22 @@ void WPAddContact::slotUpdateGroups()
kdDebug(14170) << "WPAddContact::slotUpdateGroups()" << endl;
theDialog->mHostGroup->clear();
- QStringList Groups = theAccount->getGroups();
- QStringList::ConstIterator end = Groups.end();
- for (QStringList::ConstIterator i = Groups.begin(); i != end; i++)
+ TQStringList Groups = theAccount->getGroups();
+ TQStringList::ConstIterator end = Groups.end();
+ for (TQStringList::ConstIterator i = Groups.begin(); i != end; i++)
theDialog->mHostGroup->insertItem(SmallIcon("network"), *i);
slotSelected(theDialog->mHostGroup->currentText());
}
-void WPAddContact::slotSelected(const QString &Group)
+void WPAddContact::slotSelected(const TQString &Group)
{
kdDebug(14170) << "WPAddContact::slotSelected(" << Group << ")" << endl;
theDialog->mHostName->clear();
- QStringList Hosts = theAccount->getHosts(Group);
- QString ownHost = theAccount->myself()->contactId();
- QStringList::ConstIterator end = Hosts.end();
- for (QStringList::ConstIterator i = Hosts.begin(); i != end; i++)
+ TQStringList Hosts = theAccount->getHosts(Group);
+ TQString ownHost = theAccount->myself()->contactId();
+ TQStringList::ConstIterator end = Hosts.end();
+ for (TQStringList::ConstIterator i = Hosts.begin(); i != end; i++)
if (*i != ownHost) theDialog->mHostName->insertItem(SmallIcon("personal"), *i);
}
@@ -84,7 +84,7 @@ bool WPAddContact::validateData()
{
kdDebug(14170) << "WPAddContact::validateData()" << endl;
- QString tmpHostName = theDialog->mHostName->currentText();
+ TQString tmpHostName = theDialog->mHostName->currentText();
if (tmpHostName.isEmpty()) {
KMessageBox::sorry(this, i18n("<qt>You must enter a valid hostname.</qt>"), i18n("WinPopup"));
@@ -93,7 +93,7 @@ bool WPAddContact::validateData()
// If our own host is not allowed as contact localhost should be forbidden as well,
// additionally somehow localhost as contact crashes when receiving a message from it?? GF
- if (tmpHostName.upper() == QString::fromLatin1("LOCALHOST")) {
+ if (tmpHostName.upper() == TQString::fromLatin1("LOCALHOST")) {
KMessageBox::sorry(this, i18n("<qt>LOCALHOST is not allowed as contact.</qt>"), i18n("WinPopup"));
return false;
}
diff --git a/kopete/protocols/winpopup/wpaddcontact.h b/kopete/protocols/winpopup/wpaddcontact.h
index 4d593cba..156e7db9 100644
--- a/kopete/protocols/winpopup/wpaddcontact.h
+++ b/kopete/protocols/winpopup/wpaddcontact.h
@@ -40,7 +40,7 @@ private:
WPAddContactBase *theDialog;
public:
- WPAddContact(QWidget *parent, WPAccount *newAccount, const char *name = 0);
+ WPAddContact(TQWidget *parent, WPAccount *newAccount, const char *name = 0);
~WPAddContact();
virtual bool validateData();
@@ -48,7 +48,7 @@ public:
public slots:
virtual bool apply(Kopete::Account *theAccount, Kopete::MetaContact *theMetaContact);
- void slotSelected(const QString &Group);
+ void slotSelected(const TQString &Group);
void slotUpdateGroups();
};
diff --git a/kopete/protocols/winpopup/wpcontact.cpp b/kopete/protocols/winpopup/wpcontact.cpp
index 7cf2529c..801b9865 100644
--- a/kopete/protocols/winpopup/wpcontact.cpp
+++ b/kopete/protocols/winpopup/wpcontact.cpp
@@ -16,7 +16,7 @@
***************************************************************************/
// Qt Includes
-#include <qregexp.h>
+#include <tqregexp.h>
// KDE Includes
#include <kdebug.h>
@@ -27,13 +27,13 @@
#include "wpcontact.h"
#include "wpaccount.h"
-WPContact::WPContact(Kopete::Account *account, const QString &newHostName, const QString &nickName, Kopete::MetaContact *metaContact)
+WPContact::WPContact(Kopete::Account *account, const TQString &newHostName, const TQString &nickName, Kopete::MetaContact *metaContact)
: Kopete::Contact(account, newHostName, metaContact)
{
// kdDebug(14170) << "WPContact::WPContact(<account>, " << newHostName << ", " << nickName << ", <parent>)" << endl;
kdDebug(14170) << "WPContact::WPContact: " << this << endl;
- QString theNickName = nickName;
+ TQString theNickName = nickName;
if (theNickName.isEmpty()) {
// Construct nickname from hostname with first letter to upper. GF
@@ -51,17 +51,17 @@ WPContact::WPContact(Kopete::Account *account, const QString &newHostName, const
// Initialise and start the periodical checking for contact's status
setOnlineStatus(static_cast<WPProtocol *>(protocol())->WPOffline);
- connect(&checkStatus, SIGNAL(timeout()), this, SLOT(slotCheckStatus()));
+ connect(&checkStatus, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotCheckStatus()));
checkStatus.start(1000, false);
}
-QPtrList<KAction> * WPContact::customContextMenuActions()
+TQPtrList<KAction> * WPContact::customContextMenuActions()
{
//myActionCollection = new KActionCollection(parent);
return 0;
}
-void WPContact::serialize(QMap<QString, QString> &serializedData, QMap<QString, QString> &addressBookData)
+void WPContact::serialize(TQMap<TQString, TQString> &serializedData, TQMap<TQString, TQString> &addressBookData)
{
// kdDebug(14170) << "WP::serialize(...)" << endl;
@@ -72,14 +72,14 @@ Kopete::ChatSession* WPContact::manager( Kopete::Contact::CanCreateFlags /*canCr
{
if (m_manager == 0) {
// Set up the message managers
- QPtrList<Kopete::Contact> singleContact;
+ TQPtrList<Kopete::Contact> singleContact;
singleContact.append(this);
m_manager = Kopete::ChatSessionManager::self()->create( account()->myself(), singleContact, protocol() );
- connect(m_manager, SIGNAL(messageSent(Kopete::Message &, Kopete::ChatSession *)), this, SLOT(slotSendMessage(Kopete::Message &)));
- connect(m_manager, SIGNAL(messageSent(Kopete::Message &, Kopete::ChatSession *)), m_manager, SLOT(appendMessage(Kopete::Message &)));
- connect(m_manager, SIGNAL(destroyed()), this, SLOT(slotChatSessionDestroyed()));
+ connect(m_manager, TQT_SIGNAL(messageSent(Kopete::Message &, Kopete::ChatSession *)), this, TQT_SLOT(slotSendMessage(Kopete::Message &)));
+ connect(m_manager, TQT_SIGNAL(messageSent(Kopete::Message &, Kopete::ChatSession *)), m_manager, TQT_SLOT(appendMessage(Kopete::Message &)));
+ connect(m_manager, TQT_SIGNAL(destroyed()), this, TQT_SLOT(slotChatSessionDestroyed()));
}
return m_manager;
@@ -111,7 +111,7 @@ void WPContact::slotUserInfo()
if (!m_infoDialog) {
m_infoDialog = new WPUserInfo( this, static_cast<WPAccount*>( account() ) );
if (!m_infoDialog) return;
- connect( m_infoDialog, SIGNAL( closing() ), this, SLOT( slotCloseUserInfoDialog() ) );
+ connect( m_infoDialog, TQT_SIGNAL( closing() ), this, TQT_SLOT( slotCloseUserInfoDialog() ) );
m_infoDialog->show();
} else {
m_infoDialog->raise();
@@ -149,14 +149,14 @@ void WPContact::slotCheckStatus()
}
}
-void WPContact::slotNewMessage(const QString &Body, const QDateTime &Arrival)
+void WPContact::slotNewMessage(const TQString &Body, const TQDateTime &Arrival)
{
kdDebug(14170) << "WPContact::slotNewMessage(" << Body << ", " << Arrival.toString() << ")" << endl;
- QPtrList<Kopete::Contact> contactList;
+ TQPtrList<Kopete::Contact> contactList;
contactList.append(account()->myself());
- QRegExp subj("^Subject: ([^\n]*)\n(.*)$");
+ TQRegExp subj("^Subject: ([^\n]*)\n(.*)$");
Kopete::Message msg;
if(subj.search(Body) == -1) {
@@ -174,7 +174,7 @@ void WPContact::slotSendMessage( Kopete::Message& message )
// Warning: this could crash
kdDebug(14170) << message.to().first() << " is " << dynamic_cast<WPContact *>( message.to().first() )->contactId() << endl;
- QString Message = (!message.subject().isEmpty() ? "Subject: " + message.subject() + "\n" : QString("")) + message.plainBody();
+ TQString Message = (!message.subject().isEmpty() ? "Subject: " + message.subject() + "\n" : TQString("")) + message.plainBody();
WPAccount *acct = dynamic_cast<WPAccount *>(account());
WPContact *contact = dynamic_cast<WPContact *>( message.to().first() );
if (acct && contact) {
diff --git a/kopete/protocols/winpopup/wpcontact.h b/kopete/protocols/winpopup/wpcontact.h
index 343e07f7..d3e13251 100644
--- a/kopete/protocols/winpopup/wpcontact.h
+++ b/kopete/protocols/winpopup/wpcontact.h
@@ -22,11 +22,11 @@
#include <kaction.h>
// Qt Includes
-//#include <qvaluestack.h>
-#include <qdatetime.h>
-#include <qptrlist.h>
-#include <qtimer.h>
-#include <qstringlist.h>
+//#include <tqvaluestack.h>
+#include <tqdatetime.h>
+#include <tqptrlist.h>
+#include <tqtimer.h>
+#include <tqstringlist.h>
// Kopete Includes
#include "kopetecontact.h"
@@ -51,18 +51,18 @@ class WPContact: public Kopete::Contact
Q_OBJECT
public:
- WPContact(Kopete::Account *account, const QString &userId, const QString &fullName, Kopete::MetaContact *metaContact);
+ WPContact(Kopete::Account *account, const TQString &userId, const TQString &fullName, Kopete::MetaContact *metaContact);
// virtual bool isOnline() const;
virtual bool isReachable();
- virtual QPtrList<KAction> *customContextMenuActions();
+ virtual TQPtrList<KAction> *customContextMenuActions();
virtual Kopete::ChatSession *manager(Kopete::Contact::CanCreateFlags = Kopete::Contact::CannotCreate);
- virtual void serialize(QMap<QString, QString> &serializedData, QMap<QString, QString> &addressBookData);
+ virtual void serialize(TQMap<TQString, TQString> &serializedData, TQMap<TQString, TQString> &addressBookData);
public slots:
virtual void slotUserInfo();
void slotCheckStatus(); // the call back for the checkStatus timer
- void slotNewMessage(const QString &Body, const QDateTime &Arrival);
+ void slotNewMessage(const TQString &Body, const TQDateTime &Arrival);
private slots:
void slotChatSessionDestroyed();
@@ -72,7 +72,7 @@ private slots:
private:
bool myWasConnected; // true if protocol connected at last check
- QTimer checkStatus; // checks the status of this contact every second or so
+ TQTimer checkStatus; // checks the status of this contact every second or so
// KActionCollection *myActionCollection;
// holds all the protocol specific actions (not many!)
Kopete::ChatSession *m_manager;
diff --git a/kopete/protocols/winpopup/wpeditaccount.cpp b/kopete/protocols/winpopup/wpeditaccount.cpp
index 454f5d6f..6e1d1aba 100644
--- a/kopete/protocols/winpopup/wpeditaccount.cpp
+++ b/kopete/protocols/winpopup/wpeditaccount.cpp
@@ -22,8 +22,8 @@
#include <unistd.h>
// QT Includes
-#include <qcheckbox.h>
-#include <qfile.h>
+#include <tqcheckbox.h>
+#include <tqfile.h>
// KDE Includes
#include <kdebug.h>
@@ -45,14 +45,14 @@
#include "wpeditaccount.h"
#include "wpprotocol.h"
-WPEditAccount::WPEditAccount(QWidget *parent, Kopete::Account *theAccount)
+WPEditAccount::WPEditAccount(TQWidget *parent, Kopete::Account *theAccount)
: WPEditAccountBase(parent), KopeteEditAccountWidget(theAccount)
{
kdDebug(14170) << "WPEditAccount::WPEditAccount(<parent>, <theAccount>)";
mProtocol = WPProtocol::protocol();
- QString tmpSmbcPath = KStandardDirs::findExe("smbclient");
+ TQString tmpSmbcPath = KStandardDirs::findExe("smbclient");
if(account()) {
mHostName->setText(account()->accountId());
@@ -65,7 +65,7 @@ WPEditAccount::WPEditAccount(QWidget *parent, Kopete::Account *theAccount)
}
else {
// no QT/KDE function? GF
- QString theHostName = QString::null;
+ TQString theHostName = TQString::null;
char *tmp = new char[255];
if (tmp != 0) {
@@ -101,7 +101,7 @@ bool WPEditAccount::validateData()
return false;
}
- QFile smbc(mSmbcPath->url());
+ TQFile smbc(mSmbcPath->url());
if (!smbc.exists()) {
KMessageBox::sorry(this, i18n("<qt>You must enter a valid smbclient path.</qt>"), i18n("WinPopup"));
return false;
diff --git a/kopete/protocols/winpopup/wpeditaccount.h b/kopete/protocols/winpopup/wpeditaccount.h
index afa521a7..4714e197 100644
--- a/kopete/protocols/winpopup/wpeditaccount.h
+++ b/kopete/protocols/winpopup/wpeditaccount.h
@@ -41,7 +41,7 @@ private:
WPAccount *mAccount;
public:
- WPEditAccount(QWidget *parent, Kopete::Account *theAccount);
+ WPEditAccount(TQWidget *parent, Kopete::Account *theAccount);
virtual bool validateData();
void writeConfig();
diff --git a/kopete/protocols/winpopup/wpprotocol.cpp b/kopete/protocols/winpopup/wpprotocol.cpp
index b765438c..71d4a76a 100644
--- a/kopete/protocols/winpopup/wpprotocol.cpp
+++ b/kopete/protocols/winpopup/wpprotocol.cpp
@@ -19,8 +19,8 @@
***************************************************************************/
// QT Includes
-#include <qmap.h>
-#include <qdict.h>
+#include <tqmap.h>
+#include <tqdict.h>
// KDE Includes
#include <kapplication.h>
@@ -48,11 +48,11 @@ typedef KGenericFactory<WPProtocol> WPProtocolFactory;
K_EXPORT_COMPONENT_FACTORY( kopete_wp, WPProtocolFactory( "kopete_wp" ) )
// WP Protocol
-WPProtocol::WPProtocol( QObject *parent, const char *name, const QStringList & /* args */ )
+WPProtocol::WPProtocol( TQObject *parent, const char *name, const TQStringList & /* args */ )
: Kopete::Protocol( WPProtocolFactory::instance(), parent, name ),
- WPOnline( Kopete::OnlineStatus::Online, 25, this, 0, QString::null, i18n("Online"), i18n("Online")),
+ WPOnline( Kopete::OnlineStatus::Online, 25, this, 0, TQString::null, i18n("Online"), i18n("Online")),
WPAway( Kopete::OnlineStatus::Away, 20, this, 1, "wp_away", i18n("Away"), i18n("Away")),
- WPOffline( Kopete::OnlineStatus::Offline, 0, this, 2, QString::null, i18n("Offline"), i18n("Offline"))
+ WPOffline( Kopete::OnlineStatus::Offline, 0, this, 2, TQString::null, i18n("Offline"), i18n("Offline"))
{
// kdDebug(14170) << "WPProtocol::WPProtocol()" << endl;
@@ -67,8 +67,8 @@ WPProtocol::WPProtocol( QObject *parent, const char *name, const QStringList & /
readConfig();
popupClient = new WinPopupLib(smbClientBin, groupCheckFreq);
- QObject::connect(popupClient, SIGNAL(signalNewMessage(const QString &, const QDateTime &, const QString &)),
- this, SLOT(slotReceivedMessage(const QString &, const QDateTime &, const QString &)));
+ TQObject::connect(popupClient, TQT_SIGNAL(signalNewMessage(const TQString &, const TQDateTime &, const TQString &)),
+ this, TQT_SLOT(slotReceivedMessage(const TQString &, const TQDateTime &, const TQString &)));
}
// Destructor
@@ -79,7 +79,7 @@ WPProtocol::~WPProtocol()
sProtocol = 0;
}
-AddContactPage *WPProtocol::createAddContactWidget(QWidget *parent, Kopete::Account *theAccount)
+AddContactPage *WPProtocol::createAddContactWidget(TQWidget *parent, Kopete::Account *theAccount)
{
// kdDebug(14170) << "WPProtocol::createAddContactWidget(<parent>, " << theAccount << ")" << endl;
@@ -87,11 +87,11 @@ AddContactPage *WPProtocol::createAddContactWidget(QWidget *parent, Kopete::Acco
}
Kopete::Contact *WPProtocol::deserializeContact( Kopete::MetaContact *metaContact,
- const QMap<QString, QString> &serializedData,
- const QMap<QString, QString> & /* addressBookData */ )
+ const TQMap<TQString, TQString> &serializedData,
+ const TQMap<TQString, TQString> & /* addressBookData */ )
{
- QString contactId = serializedData[ "contactId" ];
- QString accountId = serializedData[ "accountId" ];
+ TQString contactId = serializedData[ "contactId" ];
+ TQString accountId = serializedData[ "accountId" ];
WPAccount *theAccount = static_cast<WPAccount *>(Kopete::AccountManager::self()->findAccount(protocol()->pluginId(), accountId));
if(!theAccount) {
@@ -108,12 +108,12 @@ Kopete::Contact *WPProtocol::deserializeContact( Kopete::MetaContact *metaContac
return theAccount->contacts()[contactId];
}
-KopeteEditAccountWidget *WPProtocol::createEditAccountWidget(Kopete::Account *account, QWidget *parent)
+KopeteEditAccountWidget *WPProtocol::createEditAccountWidget(Kopete::Account *account, TQWidget *parent)
{
return new WPEditAccount(parent, account);
}
-Kopete::Account *WPProtocol::createNewAccount(const QString &accountId)
+Kopete::Account *WPProtocol::createNewAccount(const TQString &accountId)
{
return new WPAccount(this, accountId);
}
@@ -137,7 +137,7 @@ void WPProtocol::installSamba()
{
// kdDebug(14170) << "WPProtocol::installSamba()" endl;
- QStringList args;
+ TQStringList args;
args += KStandardDirs::findExe("winpopup-install.sh");
args += KStandardDirs::findExe("winpopup-send.sh");
if (KApplication::kdeinitExecWait("kdesu", args) == 0)
@@ -149,13 +149,13 @@ void WPProtocol::installSamba()
/**
* search the contact for the new message and give it to its account
*/
-void WPProtocol::slotReceivedMessage(const QString &Body, const QDateTime &Time, const QString &From)
+void WPProtocol::slotReceivedMessage(const TQString &Body, const TQDateTime &Time, const TQString &From)
{
bool foundContact = false;
- QString accountKey = QString::null;
- QDict<Kopete::Account> Accounts = Kopete::AccountManager::self()->accounts(protocol());
- for (QDictIterator<Kopete::Account> it(Accounts); it.current(); ++it) {
- QDict<Kopete::Contact> Contacts = it.current()->contacts();
+ TQString accountKey = TQString::null;
+ TQDict<Kopete::Account> Accounts = Kopete::AccountManager::self()->accounts(protocol());
+ for (TQDictIterator<Kopete::Account> it(Accounts); it.current(); ++it) {
+ TQDict<Kopete::Contact> Contacts = it.current()->contacts();
Kopete::Contact *theContact = Contacts[From];
if (theContact != 0) {
foundContact = true;
@@ -176,7 +176,7 @@ void WPProtocol::slotReceivedMessage(const QString &Body, const QDateTime &Time,
}
}
-void WPProtocol::sendMessage(const QString &Body, const QString &Destination)
+void WPProtocol::sendMessage(const TQString &Body, const TQString &Destination)
{
popupClient->sendMessage(Body, Destination);
}
diff --git a/kopete/protocols/winpopup/wpprotocol.h b/kopete/protocols/winpopup/wpprotocol.h
index 92a9e434..b54f4972 100644
--- a/kopete/protocols/winpopup/wpprotocol.h
+++ b/kopete/protocols/winpopup/wpprotocol.h
@@ -22,9 +22,9 @@
#define WPPROTOCOL_H
// QT Includes
-#include <qpixmap.h>
-#include <qptrlist.h>
-#include <qdatetime.h>
+#include <tqpixmap.h>
+#include <tqptrlist.h>
+#include <tqdatetime.h>
// Kopete Includes
#include "kopetemetacontact.h"
@@ -51,20 +51,20 @@ class WPProtocol : public Kopete::Protocol
// Kopete::Protocol overloading
public:
- WPProtocol( QObject *parent, const char *name, const QStringList &args );
+ WPProtocol( TQObject *parent, const char *name, const TQStringList &args );
~WPProtocol();
- virtual AddContactPage *createAddContactWidget(QWidget *parent, Kopete::Account *theAccount);
- virtual KopeteEditAccountWidget *createEditAccountWidget(Kopete::Account *account, QWidget *parent);
- virtual Kopete::Account *createNewAccount(const QString &accountId);
+ virtual AddContactPage *createAddContactWidget(TQWidget *parent, Kopete::Account *theAccount);
+ virtual KopeteEditAccountWidget *createEditAccountWidget(Kopete::Account *account, TQWidget *parent);
+ virtual Kopete::Account *createNewAccount(const TQString &accountId);
- const QStringList getGroups() {return popupClient->getGroups(); }
- const QStringList getHosts(const QString &Group) { return popupClient->getHosts(Group); }
- bool checkHost(const QString &Name) { return popupClient->checkHost(Name); }
+ const TQStringList getGroups() {return popupClient->getGroups(); }
+ const TQStringList getHosts(const TQString &Group) { return popupClient->getHosts(Group); }
+ bool checkHost(const TQString &Name) { return popupClient->checkHost(Name); }
// Kopete::Plugin overloading
public:
- virtual Kopete::Contact *deserializeContact(Kopete::MetaContact *metaContact, const QMap<QString, QString> &serializedData, const QMap<QString, QString> &addressBookData);
+ virtual Kopete::Contact *deserializeContact(Kopete::MetaContact *metaContact, const TQMap<TQString, TQString> &serializedData, const TQMap<TQString, TQString> &addressBookData);
// Stuff used internally & by colleague classes
public:
@@ -73,15 +73,15 @@ public:
const Kopete::OnlineStatus WPOnline;
const Kopete::OnlineStatus WPAway;
const Kopete::OnlineStatus WPOffline;
- void sendMessage(const QString &Body, const QString &Destination);
+ void sendMessage(const TQString &Body, const TQString &Destination);
void settingsChanged(void); // Callback when settings changed
public slots:
void installSamba(); // Modify smb.conf to use winpopup-send.sh script
- void slotReceivedMessage(const QString &Body, const QDateTime &Time, const QString &From);
+ void slotReceivedMessage(const TQString &Body, const TQDateTime &Time, const TQString &From);
private:
- QString smbClientBin;
+ TQString smbClientBin;
int groupCheckFreq;
void readConfig();
WinPopupLib *popupClient;
diff --git a/kopete/protocols/winpopup/wpuserinfo.cpp b/kopete/protocols/winpopup/wpuserinfo.cpp
index 7e4348d4..e50805f5 100644
--- a/kopete/protocols/winpopup/wpuserinfo.cpp
+++ b/kopete/protocols/winpopup/wpuserinfo.cpp
@@ -19,7 +19,7 @@
***************************************************************************/
// QT Includes
-#include <qregexp.h>
+#include <tqregexp.h>
// KDE Includes
#include <kdebug.h>
@@ -32,8 +32,8 @@
#include "wpaccount.h"
#include "wpcontact.h"
-WPUserInfo::WPUserInfo( WPContact *contact, WPAccount */*account*/, QWidget *parent, const char* name )
- : KDialogBase( parent, name, false, QString::null, Close, Close, false ), m_contact(contact),
+WPUserInfo::WPUserInfo( WPContact *contact, WPAccount */*account*/, TQWidget *parent, const char* name )
+ : KDialogBase( parent, name, false, TQString::null, Close, Close, false ), m_contact(contact),
Comment(i18n("N/A")), Workgroup(i18n("N/A")), OS(i18n("N/A")), Software(i18n("N/A"))
{
// kdDebug( 14170 ) << k_funcinfo << endl;
@@ -50,23 +50,23 @@ WPUserInfo::WPUserInfo( WPContact *contact, WPAccount */*account*/, QWidget *par
m_mainWidget->sOS->setText(i18n("Looking"));
m_mainWidget->sServer->setText(i18n("Looking"));
- connect( this, SIGNAL( closeClicked() ), this, SLOT( slotCloseClicked() ) );
+ connect( this, TQT_SIGNAL( closeClicked() ), this, TQT_SLOT( slotCloseClicked() ) );
startDetailsProcess(m_contact->contactId());
}
// I decided to do this direct here to avoid "Handstände" with signals and stuff
// if we would do this in libwinpopup. GF
-void WPUserInfo::startDetailsProcess(const QString &host)
+void WPUserInfo::startDetailsProcess(const TQString &host)
{
KGlobal::config()->setGroup("WinPopup");
- QString theSMBClientPath = KGlobal::config()->readEntry("SMBClientPath", "/usr/bin/smbclient");
+ TQString theSMBClientPath = KGlobal::config()->readEntry("SMBClientPath", "/usr/bin/smbclient");
KProcIO *details = new KProcIO;
*details << theSMBClientPath << "-N" << "-E" << "-g" << "-L" << host << "-";
- connect(details, SIGNAL(readReady(KProcIO *)), this, SLOT(slotDetailsProcessReady(KProcIO *)));
- connect(details, SIGNAL(processExited(KProcess *)), this, SLOT(slotDetailsProcessExited(KProcess *)));
+ connect(details, TQT_SIGNAL(readReady(KProcIO *)), this, TQT_SLOT(slotDetailsProcessReady(KProcIO *)));
+ connect(details, TQT_SIGNAL(processExited(KProcess *)), this, TQT_SLOT(slotDetailsProcessExited(KProcess *)));
if (!details->start(KProcess::NotifyOnExit, KProcess::Stderr)) {
slotDetailsProcessExited(details);
@@ -76,8 +76,8 @@ void WPUserInfo::startDetailsProcess(const QString &host)
void WPUserInfo::slotDetailsProcessReady(KProcIO *d)
{
- QString tmpLine = QString::null;
- QRegExp info("^Domain=\\[(.*)\\]\\sOS=\\[(.*)\\]\\sServer=\\[(.*)\\]$"), host("^Server\\|(.*)\\|(.*)$");
+ TQString tmpLine = TQString::null;
+ TQRegExp info("^Domain=\\[(.*)\\]\\sOS=\\[(.*)\\]\\sServer=\\[(.*)\\]$"), host("^Server\\|(.*)\\|(.*)$");
while (d->readln(tmpLine) > -1) {
if (info.search(tmpLine) != -1) {
diff --git a/kopete/protocols/winpopup/wpuserinfo.h b/kopete/protocols/winpopup/wpuserinfo.h
index 1c4ce0e9..2059ba2c 100644
--- a/kopete/protocols/winpopup/wpuserinfo.h
+++ b/kopete/protocols/winpopup/wpuserinfo.h
@@ -36,9 +36,9 @@ class WPUserInfo : public KDialogBase
Q_OBJECT
public:
- WPUserInfo( WPContact *, WPAccount *, QWidget *parent = 0, const char* name = "WPUserInfo" );
+ WPUserInfo( WPContact *, WPAccount *, TQWidget *parent = 0, const char* name = "WPUserInfo" );
- void startDetailsProcess(const QString &host);
+ void startDetailsProcess(const TQString &host);
private slots:
void slotDetailsProcessReady(KProcIO *d);
@@ -52,7 +52,7 @@ class WPUserInfo : public KDialogBase
WPContact *m_contact;
WPUserInfoWidget *m_mainWidget;
- QString Comment, Workgroup, OS, Software;
+ TQString Comment, Workgroup, OS, Software;
};
#endif