From 83677e35509b4dafac63b76995652bdf3b49f209 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Fri, 16 Dec 2011 09:59:34 -0600 Subject: Revert "Rename a number of old tq methods that are no longer tq specific" This reverts commit 808e453c56036211f57482ed847d54aca01bba68. --- .../jabber/libiris/iris/xmpp-im/client.cpp | 88 +++++++++++----------- 1 file changed, 44 insertions(+), 44 deletions(-) (limited to 'kopete/protocols/jabber/libiris/iris/xmpp-im/client.cpp') diff --git a/kopete/protocols/jabber/libiris/iris/xmpp-im/client.cpp b/kopete/protocols/jabber/libiris/iris/xmpp-im/client.cpp index b7d5e00c..973b6c73 100644 --- a/kopete/protocols/jabber/libiris/iris/xmpp-im/client.cpp +++ b/kopete/protocols/jabber/libiris/iris/xmpp-im/client.cpp @@ -208,13 +208,13 @@ void Client::start(const TQString &host, const TQString &user, const TQString &p d->pass = pass; d->resource = _resource; - Status stat; + tqStatus stat; stat.setIsAvailable(false); d->resourceList += Resource(resource(), stat); JT_PushPresence *pp = new JT_PushPresence(rootTask()); connect(pp, TQT_SIGNAL(subscription(const Jid &, const TQString &)), TQT_SLOT(ppSubscription(const Jid &, const TQString &))); - connect(pp, TQT_SIGNAL(presence(const Jid &, const Status &)), TQT_SLOT(ppPresence(const Jid &, const Status &))); + connect(pp, TQT_SIGNAL(presence(const Jid &, const tqStatus &)), TQT_SLOT(ppPresence(const Jid &, const tqStatus &))); JT_PushMessage *pm = new JT_PushMessage(rootTask()); connect(pm, TQT_SIGNAL(message(const Message &)), TQT_SLOT(pmMessage(const Message &))); @@ -267,7 +267,7 @@ bool Client::isActive() const return d->active; } -void Client::groupChatChangeNick(const TQString &host, const TQString &room, const TQString &nick, const Status &_s) +void Client::groupChatChangeNick(const TQString &host, const TQString &room, const TQString &nick, const tqStatus &_s) { Jid jid(room + "@" + host + "/" + nick); for(TQValueList::Iterator it = d->groupChatList.begin(); it != d->groupChatList.end(); it++) { @@ -275,7 +275,7 @@ void Client::groupChatChangeNick(const TQString &host, const TQString &room, con if(i.j.compare(jid, false)) { i.j = jid; - Status s = _s; + tqStatus s = _s; s.setIsAvailable(true); JT_Presence *j = new JT_Presence(rootTask()); @@ -303,14 +303,14 @@ bool Client::groupChatJoin(const TQString &host, const TQString &room, const TQS ++it; } - debug(TQString("Client: Joined: [%1]\n").arg(jid.full())); + debug(TQString("Client: Joined: [%1]\n").tqarg(jid.full())); GroupChat i; i.j = jid; i.status = GroupChat::Connecting; d->groupChatList += i; JT_Presence *j = new JT_Presence(rootTask()); - j->pres(jid, Status()); + j->pres(jid, tqStatus()); j->go(true); return true; @@ -332,20 +332,20 @@ bool Client::groupChatJoin(const TQString &host, const TQString &room, const TQS ++it; } - debug(TQString("Client: Joined: [%1]\n").arg(jid.full())); + debug(TQString("Client: Joined: [%1]\n").tqarg(jid.full())); GroupChat i; i.j = jid; i.status = GroupChat::Connecting; d->groupChatList += i; JT_MucPresence *j = new JT_MucPresence(rootTask()); - j->pres(jid, Status(), password); + j->pres(jid, tqStatus(), password); j->go(true); return true; } -void Client::groupChatSetStatus(const TQString &host, const TQString &room, const Status &_s) +void Client::groupChatSettqStatus(const TQString &host, const TQString &room, const tqStatus &_s) { Jid jid(room + "@" + host); bool found = false; @@ -360,7 +360,7 @@ void Client::groupChatSetStatus(const TQString &host, const TQString &room, cons if(!found) return; - Status s = _s; + tqStatus s = _s; s.setIsAvailable(true); JT_Presence *j = new JT_Presence(rootTask()); @@ -378,10 +378,10 @@ void Client::groupChatLeave(const TQString &host, const TQString &room) continue; i.status = GroupChat::Closing; - debug(TQString("Client: Leaving: [%1]\n").arg(i.j.full())); + debug(TQString("Client: Leaving: [%1]\n").tqarg(i.j.full())); JT_Presence *j = new JT_Presence(rootTask()); - Status s; + tqStatus s; s.setIsAvailable(false); j->pres(i.j, s); j->go(true); @@ -410,7 +410,7 @@ void Client::close(bool) i.status = GroupChat::Closing; JT_Presence *j = new JT_Presence(rootTask()); - Status s; + tqStatus s; s.setIsAvailable(false); j->pres(i.j, s); j->go(true); @@ -493,7 +493,7 @@ static TQDomElement oldStyleNS(const TQDomElement &e) if(!noShowNS) i.setAttribute("xmlns", e.namespaceURI()); - // copy children + // copy tqchildren TQDomNodeList nl = e.childNodes(); for(x = 0; x < nl.count(); ++x) { TQDomNode n = nl.item(x); @@ -514,7 +514,7 @@ void Client::streamReadyRead() Stanza s = d->stream->read(); TQString out = s.toString(); - debug(TQString("Client: incoming: [\n%1]\n").arg(out)); + debug(TQString("Client: incoming: [\n%1]\n").tqarg(out)); xmlIncoming(out); TQDomElement x = oldStyleNS(s.element()); @@ -607,7 +607,7 @@ static TQDomElement addCorrectNS(const TQDomElement &e) i.setAttributeNodeNS(a.cloneNode().toAttr()); } - // copy children + // copy tqchildren TQDomNodeList nl = e.childNodes(); for(x = 0; x < nl.count(); ++x) { TQDomNode n = nl.item(x); @@ -631,7 +631,7 @@ void Client::send(const TQDomElement &x) //x.save(ts, 0); //TQString out = Stream::xmlToString(x); - //debug(TQString("Client: outgoing: [\n%1]\n").arg(out)); + //debug(TQString("Client: outgoing: [\n%1]\n").tqarg(out)); //xmlOutgoing(out); TQDomElement e = addCorrectNS(x); @@ -642,7 +642,7 @@ void Client::send(const TQDomElement &x) } TQString out = s.toString(); - debug(TQString("Client: outgoing: [\n%1]\n").arg(out)); + debug(TQString("Client: outgoing: [\n%1]\n").tqarg(out)); xmlOutgoing(out); //printf("x[%s] x2[%s] s[%s]\n", Stream::xmlToString(x).latin1(), Stream::xmlToString(e).latin1(), s.toString().latin1()); @@ -654,7 +654,7 @@ void Client::send(const TQString &str) if(!d->stream) return; - debug(TQString("Client: outgoing: [\n%1]\n").arg(str)); + debug(TQString("Client: outgoing: [\n%1]\n").tqarg(str)); xmlOutgoing(str); static_cast(d->stream)->writeDirect(str); } @@ -713,12 +713,12 @@ void Client::ppSubscription(const Jid &j, const TQString &s) subscription(j, s); } -void Client::ppPresence(const Jid &j, const Status &s) +void Client::ppPresence(const Jid &j, const tqStatus &s) { if(s.isAvailable()) - debug(TQString("Client: %1 is available.\n").arg(j.full())); + debug(TQString("Client: %1 is available.\n").tqarg(j.full())); else - debug(TQString("Client: %1 is unavailable.\n").arg(j.full())); + debug(TQString("Client: %1 is unavailable.\n").tqarg(j.full())); for(TQValueList::Iterator it = d->groupChatList.begin(); it != d->groupChatList.end(); it++) { GroupChat &i = *it; @@ -726,7 +726,7 @@ void Client::ppPresence(const Jid &j, const Status &s) if(i.j.compare(j, false)) { bool us = (i.j.resource() == j.resource() || j.resource().isEmpty()) ? true: false; - debug(TQString("for groupchat i=[%1] pres=[%2], [us=%3].\n").arg(i.j.full()).arg(j.full()).arg(us)); + debug(TQString("for groupchat i=[%1] pres=[%2], [us=%3].\n").tqarg(i.j.full()).tqarg(j.full()).tqarg(us)); switch(i.status) { case GroupChat::Connecting: if(us && s.hasError()) { @@ -789,7 +789,7 @@ void Client::ppPresence(const Jid &j, const Status &s) } } -void Client::updateSelfPresence(const Jid &j, const Status &s) +void Client::updateSelfPresence(const Jid &j, const tqStatus &s) { ResourceList::Iterator rit = d->resourceList.find(j.resource()); bool found = (rit == d->resourceList.end()) ? false: true; @@ -797,8 +797,8 @@ void Client::updateSelfPresence(const Jid &j, const Status &s) // unavailable? remove the resource if(!s.isAvailable()) { if(found) { - debug(TQString("Client: Removing self resource: name=[%1]\n").arg(j.resource())); - (*rit).setStatus(s); + debug(TQString("Client: Removing self resource: name=[%1]\n").tqarg(j.resource())); + (*rit).settqStatus(s); resourceUnavailable(j, *rit); d->resourceList.remove(rit); } @@ -809,19 +809,19 @@ void Client::updateSelfPresence(const Jid &j, const Status &s) if(!found) { r = Resource(j.resource(), s); d->resourceList += r; - debug(TQString("Client: Adding self resource: name=[%1]\n").arg(j.resource())); + debug(TQString("Client: Adding self resource: name=[%1]\n").tqarg(j.resource())); } else { - (*rit).setStatus(s); + (*rit).settqStatus(s); r = *rit; - debug(TQString("Client: Updating self resource: name=[%1]\n").arg(j.resource())); + debug(TQString("Client: Updating self resource: name=[%1]\n").tqarg(j.resource())); } resourceAvailable(j, r); } } -void Client::updatePresence(LiveRosterItem *i, const Jid &j, const Status &s) +void Client::updatePresence(LiveRosterItem *i, const Jid &j, const tqStatus &s) { ResourceList::Iterator rit = i->resourceList().find(j.resource()); bool found = (rit == i->resourceList().end()) ? false: true; @@ -829,11 +829,11 @@ void Client::updatePresence(LiveRosterItem *i, const Jid &j, const Status &s) // unavailable? remove the resource if(!s.isAvailable()) { if(found) { - (*rit).setStatus(s); - debug(TQString("Client: Removing resource from [%1]: name=[%2]\n").arg(i->jid().full()).arg(j.resource())); + (*rit).settqStatus(s); + debug(TQString("Client: Removing resource from [%1]: name=[%2]\n").tqarg(i->jid().full()).tqarg(j.resource())); resourceUnavailable(j, *rit); i->resourceList().remove(rit); - i->setLastUnavailableStatus(s); + i->setLastUnavailabletqStatus(s); } } // available? add/update the resource @@ -842,12 +842,12 @@ void Client::updatePresence(LiveRosterItem *i, const Jid &j, const Status &s) if(!found) { r = Resource(j.resource(), s); i->resourceList() += r; - debug(TQString("Client: Adding resource to [%1]: name=[%2]\n").arg(i->jid().full()).arg(j.resource())); + debug(TQString("Client: Adding resource to [%1]: name=[%2]\n").tqarg(i->jid().full()).tqarg(j.resource())); } else { - (*rit).setStatus(s); + (*rit).settqStatus(s); r = *rit; - debug(TQString("Client: Updating resource to [%1]: name=[%2]\n").arg(i->jid().full()).arg(j.resource())); + debug(TQString("Client: Updating resource to [%1]: name=[%2]\n").tqarg(i->jid().full()).tqarg(j.resource())); } resourceAvailable(j, r); @@ -856,7 +856,7 @@ void Client::updatePresence(LiveRosterItem *i, const Jid &j, const Status &s) void Client::pmMessage(const Message &m) { - debug(TQString("Client: Message from %1\n").arg(m.from().full())); + debug(TQString("Client: Message from %1\n").tqarg(m.from().full())); if(m.type() == "groupchat") { for(TQValueList::Iterator it = d->groupChatList.begin(); it != d->groupChatList.end(); it++) { @@ -994,7 +994,7 @@ void Client::sendSubscription(const Jid &jid, const TQString &type) j->go(true); } -void Client::setPresence(const Status &s) +void Client::setPresence(const tqStatus &s) { JT_Presence *j = new JT_Presence(rootTask()); j->pres(s); @@ -1004,7 +1004,7 @@ void Client::setPresence(const Status &s) ppPresence(jid(), s); //ResourceList::Iterator rit = d->resourceList.find(resource()); //Resource &r = *rit; - //r.setStatus(s); + //r.settqStatus(s); } TQString Client::OSName() const @@ -1363,7 +1363,7 @@ void Task::debug(const char *fmt, ...) void Task::debug(const TQString &str) { - client()->debug(TQString("%1: ").arg(className()) + str); + client()->debug(TQString("%1: ").tqarg(className()) + str); } bool Task::iqVerify(const TQDomElement &x, const Jid &to, const TQString &id, const TQString &xmlns) @@ -1462,9 +1462,9 @@ bool LiveRosterItem::isAvailable() const return false; } -const Status & LiveRosterItem::lastUnavailableStatus() const +const tqStatus & LiveRosterItem::lastUnavailabletqStatus() const { - return v_lastUnavailableStatus; + return v_lastUnavailabletqStatus; } bool LiveRosterItem::flagForDelete() const @@ -1472,9 +1472,9 @@ bool LiveRosterItem::flagForDelete() const return v_flagForDelete; } -void LiveRosterItem::setLastUnavailableStatus(const Status &s) +void LiveRosterItem::setLastUnavailabletqStatus(const tqStatus &s) { - v_lastUnavailableStatus = s; + v_lastUnavailabletqStatus = s; } void LiveRosterItem::setFlagForDelete(bool b) -- cgit v1.2.1