From 69cac65817d949cda2672ec4f0aa73d5e66a0ba1 Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 22 Jun 2011 00:30:31 +0000 Subject: TQt4 port kdenetwork This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdenetwork@1237912 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kopete/protocols/oscar/icq/icqprotocol.cpp | 46 +++++++++++++++--------------- 1 file changed, 23 insertions(+), 23 deletions(-) (limited to 'kopete/protocols/oscar/icq/icqprotocol.cpp') diff --git a/kopete/protocols/oscar/icq/icqprotocol.cpp b/kopete/protocols/oscar/icq/icqprotocol.cpp index 79fd2848..e7a5dc6c 100644 --- a/kopete/protocols/oscar/icq/icqprotocol.cpp +++ b/kopete/protocols/oscar/icq/icqprotocol.cpp @@ -66,7 +66,7 @@ K_EXPORT_COMPONENT_FACTORY( kopete_icq, ICQProtocolFactory( "kopete_icq" ) ) ICQProtocolHandler::ICQProtocolHandler() : Kopete::MimeTypeHandler(false) { - registerAsMimeHandler(TQString::fromLatin1("application/x-icq")); + registerAsMimeHandler(TQString::tqfromLatin1("application/x-icq")); } void ICQProtocolHandler::handleURL(const TQString &mimeType, const KURL & url) const @@ -141,11 +141,11 @@ void ICQProtocolHandler::handleURL(const TQString &mimeType, const KURL & url) c } TQString nickuin = nick.isEmpty() ? - i18n("'%1'").arg(uin) : - i18n("'%1' (%2)").arg(nick, uin); + i18n("'%1'").tqarg(uin) : + i18n("'%1' (%2)").tqarg(nick, uin); if (KMessageBox::questionYesNo(Kopete::UI::Global::mainWidget(), - i18n("Do you want to add %1 to your contact list?").arg(nickuin), TQString::null, i18n("Add"), i18n("Do Not Add")) + i18n("Do you want to add %1 to your contact list?").tqarg(nickuin), TQString(), i18n("Add"), i18n("Do Not Add")) != KMessageBox::Yes) { kdDebug(14153) << k_funcinfo << "Cancelled" << endl; @@ -173,16 +173,16 @@ void ICQProtocolHandler::handleURL(const TQString &mimeType, const KURL & url) c ICQProtocol* ICQProtocol::protocolStatic_ = 0L; -ICQProtocol::ICQProtocol(TQObject *parent, const char *name, const TQStringList&) -: Kopete::Protocol( ICQProtocolFactory::instance(), parent, name ), +ICQProtocol::ICQProtocol(TQObject *tqparent, const char *name, const TQStringList&) +: Kopete::Protocol( ICQProtocolFactory::instance(), tqparent, name ), firstName(Kopete::Global::Properties::self()->firstName()), lastName(Kopete::Global::Properties::self()->lastName()), awayMessage(Kopete::Global::Properties::self()->awayMessage()), emailAddress(Kopete::Global::Properties::self()->emailAddress()), ipAddress("ipAddress", i18n("IP Address") ), clientFeatures("clientFeatures", i18n("Client Features"), 0, false), - buddyIconHash("iconHash", i18n("Buddy Icon MD5 Hash"), TQString::null, true, false, true), - contactEncoding( "contactEncoding", i18n( "Contact Encoding" ), TQString::null, true, false, true ) + buddyIconHash("iconHash", i18n("Buddy Icon MD5 Hash"), TQString(), true, false, true), + contactEncoding( "contactEncoding", i18n( "Contact Encoding" ), TQString(), true, false, true ) { if (protocolStatic_) @@ -219,7 +219,7 @@ void ICQProtocol::initGenders() void ICQProtocol::initCountries() { mCountries.insert(0, ""); // unspecified - KLocale *kl = KGlobal::locale(); //KLocale(TQString::fromLatin1("kopete")); + KLocale *kl = KGlobal::locale(); //KLocale(TQString::tqfromLatin1("kopete")); mCountries.insert(93, kl->twoAlphaToCountryName("af")); mCountries.insert(355, kl->twoAlphaToCountryName("al")); @@ -468,7 +468,7 @@ void ICQProtocol::initCountries() void ICQProtocol::initLang() { - KLocale *kl = KGlobal::locale(); //KLocale(TQString::fromLatin1("kopete")); + KLocale *kl = KGlobal::locale(); //KLocale(TQString::tqfromLatin1("kopete")); mLanguages.insert(0 , ""); mLanguages.insert(1 , kl->twoAlphaToLanguageName("ar") /*i18n("Arabic")*/); @@ -673,7 +673,7 @@ void ICQProtocol::setComboFromTable(TQComboBox *box, const TQMap { // kdDebug(14153) << k_funcinfo << "Called." << endl; TQMap::ConstIterator it; - it = map.find(value); + it = map.tqfind(value); if (!(*it)) return; @@ -770,37 +770,37 @@ Kopete::Contact *ICQProtocol::deserializeContact( Kopete::MetaContact *metaConta uint ssiGid = 0, ssiBid = 0, ssiType = 0xFFFF; TQString ssiName; bool ssiWaitingAuth = false; - if ( serializedData.contains( "ssi_name" ) ) + if ( serializedData.tqcontains( "ssi_name" ) ) ssiName = serializedData["ssi_name"]; - if ( serializedData.contains( "ssi_waitingAuth" ) ) + if ( serializedData.tqcontains( "ssi_waitingAuth" ) ) { - TQString authStatus = serializedData["ssi_waitingAuth"]; - if ( authStatus == "true" ) + TQString authtqStatus = serializedData["ssi_waitingAuth"]; + if ( authtqStatus == "true" ) ssiWaitingAuth = true; } - if ( serializedData.contains( "ssi_gid" ) ) + if ( serializedData.tqcontains( "ssi_gid" ) ) ssiGid = serializedData["ssi_gid"].toUInt(); - if ( serializedData.contains( "ssi_bid" ) ) + if ( serializedData.tqcontains( "ssi_bid" ) ) ssiBid = serializedData["ssi_bid"].toUInt(); - if ( serializedData.contains( "ssi_type" ) ) + if ( serializedData.tqcontains( "ssi_type" ) ) ssiType = serializedData["ssi_type"].toUInt(); Oscar::SSI item( ssiName, ssiGid, ssiBid, ssiType, TQValueList(), 0 ); item.setWaitingAuth( ssiWaitingAuth ); - ICQContact *c = new ICQContact( account, contactId, metaContact, TQString::null, item ); + ICQContact *c = new ICQContact( account, contactId, metaContact, TQString(), item ); return c; } -AddContactPage *ICQProtocol::createAddContactWidget(TQWidget *parent, Kopete::Account *account) +AddContactPage *ICQProtocol::createAddContactWidget(TQWidget *tqparent, Kopete::Account *account) { - return new ICQAddContactPage( static_cast( account ), parent); + return new ICQAddContactPage( static_cast( account ), tqparent); } -KopeteEditAccountWidget *ICQProtocol::createEditAccountWidget(Kopete::Account *account, TQWidget *parent) +KopeteEditAccountWidget *ICQProtocol::createEditAccountWidget(Kopete::Account *account, TQWidget *tqparent) { - return new ICQEditAccountWidget(this, account, parent); + return new ICQEditAccountWidget(this, account, tqparent); } Kopete::Account *ICQProtocol::createNewAccount(const TQString &accountId) -- cgit v1.2.1