diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:48:06 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:48:06 +0000 |
commit | 47c8a359c5276062c4bc17f0e82410f29081b502 (patch) | |
tree | 2d54a5f60a5b74067632f9ef6df58c2bc38155e6 /kopete/libkopete/kopeteaway.cpp | |
parent | 6f82532777a35e0e60bbd2b290b2e93e646f349b (diff) | |
download | tdenetwork-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/libkopete/kopeteaway.cpp')
-rw-r--r-- | kopete/libkopete/kopeteaway.cpp | 52 |
1 files changed, 26 insertions, 26 deletions
diff --git a/kopete/libkopete/kopeteaway.cpp b/kopete/libkopete/kopeteaway.cpp index fa500e0c..1c920f31 100644 --- a/kopete/libkopete/kopeteaway.cpp +++ b/kopete/libkopete/kopeteaway.cpp @@ -30,7 +30,7 @@ #include "kopeteprefs.h" #include <kconfig.h> -#include <qtimer.h> +#include <tqtimer.h> #include <kapplication.h> #include <dcopref.h> @@ -59,18 +59,18 @@ struct KopeteAwayPrivate { - QString awayMessage; - QString autoAwayMessage; + TQString awayMessage; + TQString autoAwayMessage; bool useAutoAwayMessage; bool globalAway; - QStringList awayMessageList; - QTime idleTime; - QTimer *timer; + TQStringList awayMessageList; + TQTime idleTime; + TQTimer *timer; bool autoaway; bool goAvailable; int awayTimeout; bool useAutoAway; - QPtrList<Kopete::Account> autoAwayAccounts; + TQPtrList<Kopete::Account> autoAwayAccounts; int mouse_x; int mouse_y; @@ -87,7 +87,7 @@ struct KopeteAwayPrivate Kopete::Away *Kopete::Away::instance = 0L; -Kopete::Away::Away() : QObject( kapp , "Kopete::Away") +Kopete::Away::Away() : TQObject( kapp , "Kopete::Away") { int dummy = 0; dummy = dummy; // shut up @@ -95,8 +95,8 @@ Kopete::Away::Away() : QObject( kapp , "Kopete::Away") d = new KopeteAwayPrivate; // Set up the away messages - d->awayMessage = QString::null; - d->autoAwayMessage = QString::null; + d->awayMessage = TQString::null; + d->autoAwayMessage = TQString::null; d->useAutoAwayMessage = false; d->globalAway = false; d->autoaway = false; @@ -143,7 +143,7 @@ Kopete::Away::Away() : QObject( kapp , "Kopete::Away") load(); - KSettings::Dispatcher::self()->registerInstance( KGlobal::instance(), this, SLOT( load() ) ); + KSettings::Dispatcher::self()->registerInstance( KGlobal::instance(), this, TQT_SLOT( load() ) ); // Set up the config object KConfig *config = KGlobal::config(); /* Load the saved away messages */ @@ -156,8 +156,8 @@ Kopete::Away::Away() : QObject( kapp , "Kopete::Away") } else if(config->hasKey("Titles")) // Old config format { - QStringList titles = config->readListEntry("Titles"); // Get the titles - for(QStringList::iterator i = titles.begin(); i != titles.end(); ++i) + TQStringList titles = config->readListEntry("Titles"); // Get the titles + for(TQStringList::iterator i = titles.begin(); i != titles.end(); ++i) { d->awayMessageList.append( config->readEntry(*i) ); // And add it to the list } @@ -188,8 +188,8 @@ Kopete::Away::Away() : QObject( kapp , "Kopete::Away") } // init the timer - d->timer = new QTimer(this, "AwayTimer"); - connect(d->timer, SIGNAL(timeout()), this, SLOT(slotTimerTimeout())); + d->timer = new TQTimer(this, "AwayTimer"); + connect(d->timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(slotTimerTimeout())); d->timer->start(4000); //init the time and other @@ -203,17 +203,17 @@ Kopete::Away::~Away() delete d; } -QString Kopete::Away::message() +TQString Kopete::Away::message() { return getInstance()->d->awayMessage; } -QString Kopete::Away::autoAwayMessage() +TQString Kopete::Away::autoAwayMessage() { return getInstance()->d->autoAwayMessage; } -void Kopete::Away::setGlobalAwayMessage(const QString &message) +void Kopete::Away::setGlobalAwayMessage(const TQString &message) { if( !message.isEmpty() ) { @@ -223,7 +223,7 @@ void Kopete::Away::setGlobalAwayMessage(const QString &message) } } -void Kopete::Away::setAutoAwayMessage(const QString &message) +void Kopete::Away::setAutoAwayMessage(const TQString &message) { if( !message.isEmpty() ) { @@ -275,17 +275,17 @@ void Kopete::Away::load() d->useAutoAwayMessage=config->readBoolEntry("UseAutoAwayMessage", false); } -QStringList Kopete::Away::getMessages() +TQStringList Kopete::Away::getMessages() { return d->awayMessageList; } -QString Kopete::Away::getMessage( uint messageNumber ) +TQString Kopete::Away::getMessage( uint messageNumber ) { - QStringList::iterator it = d->awayMessageList.at( messageNumber ); + TQStringList::iterator it = d->awayMessageList.at( messageNumber ); if( it != d->awayMessageList.end() ) { - QString str = *it; + TQString str = *it; d->awayMessageList.prepend( str ); d->awayMessageList.remove( it ); save(); @@ -293,11 +293,11 @@ QString Kopete::Away::getMessage( uint messageNumber ) } else { - return QString::null; + return TQString::null; } } -void Kopete::Away::addMessage(const QString &message) +void Kopete::Away::addMessage(const TQString &message) { d->awayMessageList.prepend( message ); if( (int)d->awayMessageList.count() > KopetePrefs::prefs()->rememberedMessages() ) @@ -496,7 +496,7 @@ void Kopete::Away::setAutoAway() // Set all accounts that are not away already to away. // We remember them so later we only set the accounts to // available that we set to away (and not the user). - QPtrList<Kopete::Account> accounts = Kopete::AccountManager::self()->accounts(); + TQPtrList<Kopete::Account> accounts = Kopete::AccountManager::self()->accounts(); for(Kopete::Account *i=accounts.first() ; i; i=accounts.next() ) { if(i->myself()->onlineStatus().status() == Kopete::OnlineStatus::Online) |