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 --- kopete/protocols/jabber/jabbertransport.cpp | 46 ++++++++++++++--------------- 1 file changed, 23 insertions(+), 23 deletions(-) (limited to 'kopete/protocols/jabber/jabbertransport.cpp') diff --git a/kopete/protocols/jabber/jabbertransport.cpp b/kopete/protocols/jabber/jabbertransport.cpp index e7a8e7d3..26d16b28 100644 --- a/kopete/protocols/jabber/jabbertransport.cpp +++ b/kopete/protocols/jabber/jabbertransport.cpp @@ -29,8 +29,8 @@ #include -#include -#include +#include +#include #include #include #include @@ -38,7 +38,7 @@ #include "xmpp_tasks.h" -JabberTransport::JabberTransport (JabberAccount * parentAccount, const XMPP::RosterItem & item, const QString& gateway_type) +JabberTransport::JabberTransport (JabberAccount * parentAccount, const XMPP::RosterItem & item, const TQString& gateway_type) : Kopete::Account ( parentAccount->protocol(), parentAccount->accountId()+"/"+ item.jid().bare() ) { m_status=Creating; @@ -53,7 +53,7 @@ JabberTransport::JabberTransport (JabberAccount * parentAccount, const XMPP::Ros setColor( account()->color() ); #if KOPETE_IS_VERSION(0,11,51) //setCustomIcon is new in kopete 0.12 - QString cIcon; + TQString cIcon; if(gateway_type=="msn") cIcon="jabber_gateway_msn"; else if(gateway_type=="icq") @@ -83,18 +83,18 @@ JabberTransport::JabberTransport (JabberAccount * parentAccount, const XMPP::Ros configGroup()->writeEntry("GatewayJID" , item.jid().full() ); - QTimer::singleShot(0, this, SLOT(eatContacts())); + TQTimer::singleShot(0, this, TQT_SLOT(eatContacts())); m_status=Normal; } -JabberTransport::JabberTransport( JabberAccount * parentAccount, const QString & _accountId ) +JabberTransport::JabberTransport( JabberAccount * parentAccount, const TQString & _accountId ) : Kopete::Account ( parentAccount->protocol(), _accountId ) { m_status=Creating; m_account = parentAccount; - const QString contactJID_s = configGroup()->readEntry("GatewayJID"); + const TQString contactJID_s = configGroup()->readEntry("GatewayJID"); if(contactJID_s.isEmpty()) { @@ -124,13 +124,13 @@ JabberTransport::~JabberTransport () KActionMenu *JabberTransport::actionMenu () { KActionMenu *menu = new KActionMenu( accountId(), myself()->onlineStatus().iconFor( this ), this ); - QString nick = myself()->property( Kopete::Global::Properties::self()->nickName()).value().toString(); + TQString nick = myself()->property( Kopete::Global::Properties::self()->nickName()).value().toString(); menu->popupMenu()->insertTitle( myself()->onlineStatus().iconFor( myself() ), nick.isNull() ? accountLabel() : i18n( "%2 <%1>" ).arg( accountLabel(), nick ) ); - QPtrList *customActions = myself()->customContextMenuActions( ); + TQPtrList *customActions = myself()->customContextMenuActions( ); if( customActions && !customActions->isEmpty() ) { menu->popupMenu()->insertSeparator(); @@ -147,28 +147,28 @@ KActionMenu *JabberTransport::actionMenu () m_actionMenu->popupMenu()->insertSeparator(); m_actionMenu->insert(new KAction (i18n ("Join Groupchat..."), "jabber_group", 0, - this, SLOT (slotJoinNewChat ()), this, "actionJoinChat")); + this, TQT_SLOT (slotJoinNewChat ()), this, "actionJoinChat")); m_actionMenu->popupMenu()->insertSeparator(); m_actionMenu->insert ( new KAction ( i18n ("Services..."), "jabber_serv_on", 0, - this, SLOT ( slotGetServices () ), this, "actionJabberServices") ); + this, TQT_SLOT ( slotGetServices () ), this, "actionJabberServices") ); m_actionMenu->insert ( new KAction ( i18n ("Send Raw Packet to Server..."), "mail_new", 0, - this, SLOT ( slotSendRaw () ), this, "actionJabberSendRaw") ); + this, TQT_SLOT ( slotSendRaw () ), this, "actionJabberSendRaw") ); m_actionMenu->insert ( new KAction ( i18n ("Edit User Info..."), "identity", 0, - this, SLOT ( slotEditVCard () ), this, "actionEditVCard") ); + this, TQT_SLOT ( slotEditVCard () ), this, "actionEditVCard") ); return m_actionMenu;*/ } -bool JabberTransport::createContact (const QString & contactId, Kopete::MetaContact * metaContact) +bool JabberTransport::createContact (const TQString & contactId, Kopete::MetaContact * metaContact) { #if 0 //TODO // collect all group names - QStringList groupNames; + TQStringList groupNames; Kopete::GroupList groupList = metaContact->groups(); for(Kopete::Group *group = groupList.first(); group; group = groupList.next()) groupNames += group->displayName(); @@ -188,7 +188,7 @@ bool JabberTransport::createContact (const QString & contactId, Kopete::MetaCon } -void JabberTransport::setOnlineStatus( const Kopete::OnlineStatus& status , const QString &reason) +void JabberTransport::setOnlineStatus( const Kopete::OnlineStatus& status , const TQString &reason) { #if 0 if( status.status() == Kopete::OnlineStatus::Offline ) @@ -263,7 +263,7 @@ bool JabberTransport::removeAccount( ) m_status = Removing; XMPP::JT_Register *task = new XMPP::JT_Register ( m_account->client()->rootTask () ); - QObject::connect ( task, SIGNAL ( finished () ), this, SLOT ( removeAllContacts() ) ); + TQObject::connect ( task, TQT_SIGNAL ( finished () ), this, TQT_SLOT ( removeAllContacts() ) ); //JabberContact *my=static_cast(myself()); task->unreg ( myself()->contactId() ); @@ -282,7 +282,7 @@ void JabberTransport::removeAllContacts( ) */ //we don't really care, we remove everithing anyway. kdDebug(JABBER_DEBUG_GLOBAL) << k_funcinfo << "delete all contacts of the transport"<< endl; - QDictIterator it( contacts() ); + TQDictIterator it( contacts() ); for( ; it.current(); ++it ) { XMPP::JT_Roster * rosterTask = new XMPP::JT_Roster ( account()->client()->rootTask () ); @@ -293,11 +293,11 @@ void JabberTransport::removeAllContacts( ) Kopete::AccountManager::self()->removeAccount( this ); //this will delete this } -QString JabberTransport::legacyId( const XMPP::Jid & jid ) +TQString JabberTransport::legacyId( const XMPP::Jid & jid ) { if(jid.node().isEmpty()) - return QString(); - QString node = jid.node(); + return TQString(); + TQString node = jid.node(); return node.replace("%","@"); } @@ -319,8 +319,8 @@ void JabberTransport::eatContacts( ) * - Olivier 2006-01-17 - */ kdDebug(JABBER_DEBUG_GLOBAL) << k_funcinfo << endl; - QDict cts=account()->contacts(); - QDictIterator it( cts ); + TQDict cts=account()->contacts(); + TQDictIterator it( cts ); for( ; it.current(); ++it ) { JabberContact *contact=dynamic_cast(it.current()); -- cgit v1.2.1