From 808e453c56036211f57482ed847d54aca01bba68 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 15 Dec 2011 15:49:40 -0600 Subject: Rename a number of old tq methods that are no longer tq specific --- kopete/protocols/jabber/jabbercontact.cpp | 58 +++++++++++++++---------------- 1 file changed, 29 insertions(+), 29 deletions(-) (limited to 'kopete/protocols/jabber/jabbercontact.cpp') diff --git a/kopete/protocols/jabber/jabbercontact.cpp b/kopete/protocols/jabber/jabbercontact.cpp index c6147ae1..5fa3dad7 100644 --- a/kopete/protocols/jabber/jabbercontact.cpp +++ b/kopete/protocols/jabber/jabbercontact.cpp @@ -23,7 +23,7 @@ #include #include -#include +#include #include #include #include @@ -107,7 +107,7 @@ JabberContact::JabberContact (const XMPP::RosterItem &rosterItem, Kopete::Accoun * Trigger update once if we're already connected for contacts * that are being added while we are online. */ - if ( account()->myself()->onlinetqStatus().isDefinitelyOnline() ) + if ( account()->myself()->onlineStatus().isDefinitelyOnline() ) { slotGetTimedVCard (); } @@ -170,7 +170,7 @@ TQPtrList *JabberContact::customContextMenuActions () // if the contact is online, display the resources we have for it, // otherwise disable the menu - if (onlinetqStatus ().status () == Kopete::OnlineStatus::Offline) + if (onlineStatus ().status () == Kopete::OnlineStatus::Offline) { actionSelectResource->setEnabled ( false ); } @@ -263,11 +263,11 @@ void JabberContact::handleIncomingMessage (const XMPP::Message & message) { TQString room=message.invite(); TQString originalBody=message.body().isEmpty() ? TQString() : - i18n( "The original message is : \" %1 \"
" ).tqarg(TQStyleSheet::escape(message.body())); + i18n( "The original message is : \" %1 \"
" ).arg(TQStyleSheet::escape(message.body())); TQString mes=i18n("%1 invited you to join the conference %2
%3
" "If you want to accept and join, just enter your nickname and press ok
" "If you want to decline, press cancel
") - .tqarg(message.from().full(), room , originalBody); + .arg(message.from().full(), room , originalBody); bool ok=false; TQString futureNewNickName = KInputDialog::getText( i18n( "Invited to a conference - Jabber Plugin" ), @@ -299,7 +299,7 @@ void JabberContact::handleIncomingMessage (const XMPP::Message & message) if(mManager->view( Kopete::Contact::CannotCreate )) { //show an internal message if the user has not already closed his window Kopete::Message m=Kopete::Message ( this, mManager->members(), - i18n("%1 has ended their participation in the chat session.").tqarg(metaContact()->displayName()), + i18n("%1 has ended their participation in the chat session.").arg(metaContact()->displayName()), Kopete::Message::Internal ); m.setImportance(Kopete::Message::Low); mManager->view()->appendMessage ( m ); //use KopeteView::AppendMessage to bypass notifications @@ -415,7 +415,7 @@ void JabberContact::slotCheckVCard () Kopete::ContactProperty cacheDateString = property ( protocol()->propVCardCacheTimeStamp ); // don't do anything while we are offline - if ( !account()->myself()->onlinetqStatus().isDefinitelyOnline () ) + if ( !account()->myself()->onlineStatus().isDefinitelyOnline () ) { return; } @@ -440,13 +440,13 @@ void JabberContact::slotCheckVCard () // avoid warning if key does not exist in configuration file if ( cacheDateString.isNull () ) - cacheDate = TQDateTime::tqcurrentDateTime().addDays ( -2 ); + cacheDate = TQDateTime::currentDateTime().addDays ( -2 ); else cacheDate = TQDateTime::fromString ( cacheDateString.value().toString (), Qt::ISODate ); kdDebug ( JABBER_DEBUG_GLOBAL ) << k_funcinfo << "Cached vCard data for " << contactId () << " from " << cacheDate.toString () << endl; - if ( !mVCardUpdateInProgress && ( cacheDate.addDays ( 1 ) < TQDateTime::tqcurrentDateTime () ) ) + if ( !mVCardUpdateInProgress && ( cacheDate.addDays ( 1 ) < TQDateTime::currentDateTime () ) ) { kdDebug ( JABBER_DEBUG_GLOBAL ) << k_funcinfo << "Scheduling update." << endl; @@ -463,7 +463,7 @@ void JabberContact::slotGetTimedVCard () mVCardUpdateInProgress = false; // check if we are still connected - eventually we lost our connection in the meantime - if ( !account()->myself()->onlinetqStatus().isDefinitelyOnline () ) + if ( !account()->myself()->onlineStatus().isDefinitelyOnline () ) { // we are not connected, discard this update return; @@ -506,7 +506,7 @@ void JabberContact::slotGotVCard () // update timestamp of last vCard retrieval if ( metaContact() && !metaContact()->isTemporary () ) { - setProperty ( protocol()->propVCardCacheTimeStamp, TQDateTime::tqcurrentDateTime().toString ( Qt::ISODate ) ); + setProperty ( protocol()->propVCardCacheTimeStamp, TQDateTime::currentDateTime().toString ( Qt::ISODate ) ); } mVCardUpdateInProgress = false; @@ -527,7 +527,7 @@ void JabberContact::slotGotVCard () } -void JabberContact::slotCheckLastActivity ( Kopete::Contact *, const Kopete::OnlineStatus &newtqStatus, const Kopete::OnlineStatus &oldtqStatus ) +void JabberContact::slotCheckLastActivity ( Kopete::Contact *, const Kopete::OnlineStatus &newStatus, const Kopete::OnlineStatus &oldStatus ) { /* @@ -541,13 +541,13 @@ void JabberContact::slotCheckLastActivity ( Kopete::Contact *, const Kopete::Onl * to query its activity after we are already connected. */ - if ( onlinetqStatus().isDefinitelyOnline () ) + if ( onlineStatus().isDefinitelyOnline () ) { // Kopete already deals with lastSeen if the contact is online return; } - if ( ( oldtqStatus.status () == Kopete::OnlineStatus::Connecting ) && newtqStatus.isDefinitelyOnline () ) + if ( ( oldStatus.status () == Kopete::OnlineStatus::Connecting ) && newStatus.isDefinitelyOnline () ) { kdDebug ( JABBER_DEBUG_GLOBAL ) << k_funcinfo << "Scheduling request for last activity for " << mRosterItem.jid().bare () << endl; @@ -567,13 +567,13 @@ void JabberContact::slotGetTimedLastActivity () * maintained by Kopete) */ - if ( onlinetqStatus().isDefinitelyOnline () ) + if ( onlineStatus().isDefinitelyOnline () ) { // Kopete already deals with setting lastSeen if the contact is online return; } - if ( account()->myself()->onlinetqStatus().isDefinitelyOnline () ) + if ( account()->myself()->onlineStatus().isDefinitelyOnline () ) { kdDebug ( JABBER_DEBUG_GLOBAL ) << k_funcinfo << "Requesting last activity from timer for " << mRosterItem.jid().bare () << endl; @@ -591,7 +591,7 @@ void JabberContact::slotGotLastActivity () if ( task->success () ) { - setProperty ( protocol()->propLastSeen, TQDateTime(TQDateTime::tqcurrentDateTime().addSecs ( -task->seconds () ))); + setProperty ( protocol()->propLastSeen, TQDateTime(TQDateTime::currentDateTime().addSecs ( -task->seconds () ))); if( !task->message().isEmpty() ) { setProperty( protocol()->propAwayMessage, task->message() ); @@ -1110,7 +1110,7 @@ void JabberContact::slotSelectResource () } -void JabberContact::sendPresence ( const XMPP::tqStatus status ) +void JabberContact::sendPresence ( const XMPP::Status status ) { if ( !account()->isConnected () ) @@ -1119,15 +1119,15 @@ void JabberContact::sendPresence ( const XMPP::tqStatus status ) return; } - XMPP::tqStatus newtqStatus = status; + XMPP::Status newStatus = status; // honour our priority - if(newtqStatus.isAvailable()) - newtqStatus.setPriority ( account()->configGroup()->readNumEntry ( "Priority", 5 ) ); + if(newStatus.isAvailable()) + newStatus.setPriority ( account()->configGroup()->readNumEntry ( "Priority", 5 ) ); XMPP::JT_Presence * task = new XMPP::JT_Presence ( account()->client()->rootTask () ); - task->pres ( bestAddress (), newtqStatus); + task->pres ( bestAddress (), newStatus); task->go ( true ); } @@ -1136,7 +1136,7 @@ void JabberContact::sendPresence ( const XMPP::tqStatus status ) void JabberContact::slotStatusOnline () { - XMPP::tqStatus status; + XMPP::Status status; status.setShow(""); sendPresence ( status ); @@ -1146,7 +1146,7 @@ void JabberContact::slotStatusOnline () void JabberContact::slotStatusChatty () { - XMPP::tqStatus status; + XMPP::Status status; status.setShow ("chat"); sendPresence ( status ); @@ -1156,7 +1156,7 @@ void JabberContact::slotStatusChatty () void JabberContact::slotStatusAway () { - XMPP::tqStatus status; + XMPP::Status status; status.setShow ("away"); sendPresence ( status ); @@ -1166,7 +1166,7 @@ void JabberContact::slotStatusAway () void JabberContact::slotStatusXA () { - XMPP::tqStatus status; + XMPP::Status status; status.setShow ("xa"); sendPresence ( status ); @@ -1176,7 +1176,7 @@ void JabberContact::slotStatusXA () void JabberContact::slotStatusDND () { - XMPP::tqStatus status; + XMPP::Status status; status.setShow ("dnd"); sendPresence ( status ); @@ -1187,7 +1187,7 @@ void JabberContact::slotStatusDND () void JabberContact::slotStatusInvisible () { - XMPP::tqStatus status; + XMPP::Status status; status.setIsAvailable( false ); sendPresence ( status ); @@ -1299,7 +1299,7 @@ void JabberContact::slotDiscoFinished( ) XMPP::RosterItem ri = rosterItem(); Kopete::MetaContact *mc=metaContact(); JabberAccount *parentAccount=account(); - Kopete::OnlineStatus status=onlinetqStatus(); + Kopete::OnlineStatus status=onlineStatus(); kdDebug(JABBER_DEBUG_GLOBAL) << k_funcinfo << ri.jid().full() << " is not a contact but a gateway - " << this << endl; -- cgit v1.2.1