From 374d939d8af431477ce2601815f0ba121b66871c Mon Sep 17 00:00:00 2001 From: tpearson Date: Tue, 15 Feb 2011 19:11:41 +0000 Subject: Allow kdelibs to function correctly with TQt for Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdelibs@1220926 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- dcop/client/dcop.cpp | 2 +- dcop/client/dcopfind.cpp | 2 +- dcop/dcopclient.cpp | 5 +++-- dcop/dcopserver.cpp | 4 ++-- 4 files changed, 7 insertions(+), 6 deletions(-) (limited to 'dcop') diff --git a/dcop/client/dcop.cpp b/dcop/client/dcop.cpp index a76610505..c58945904 100644 --- a/dcop/client/dcop.cpp +++ b/dcop/client/dcop.cpp @@ -262,7 +262,7 @@ int callFunction( const char* app, const char* obj, const char* func, const QCSt } if ( s == static_cast(partl.count())-1) { - partl.remove(partl.at(s)); + partl.remove(partl.tqat(s)); } lt = partl.join(" "); diff --git a/dcop/client/dcopfind.cpp b/dcop/client/dcopfind.cpp index 0cc48c435..9d5e6182f 100644 --- a/dcop/client/dcopfind.cpp +++ b/dcop/client/dcopfind.cpp @@ -98,7 +98,7 @@ bool findObject( const char* app, const char* obj, const char* func, QCStringLis } if (s==(int)partl.count()-1) { - partl.remove(partl.at(s)); + partl.remove(partl.tqat(s)); } lt = partl.join(" "); diff --git a/dcop/dcopclient.cpp b/dcop/dcopclient.cpp index 8f4b7ce15..892884af3 100644 --- a/dcop/dcopclient.cpp +++ b/dcop/dcopclient.cpp @@ -483,7 +483,7 @@ void DCOPProcessInternal( DCOPClientPrivate *d, int opcode, CARD32 key, const TQ int datalen = reply.size(); pMsg->key = key; pMsg->length += datalen; - IceSendData( iceConn, datalen, const_cast(reply.data())); + IceSendData( iceConn, datalen, reply.data()); return; } @@ -1617,7 +1617,8 @@ bool DCOPClient::receive(const TQCString &/*app*/, const TQCString &objId, // fall through and send to object proxies } - if (!objId.isEmpty() && objId[objId.length()-1] == '*') { +// if (!objId.isEmpty() && objId[objId.length()-1] == '*') { + if (!objId.isEmpty() && ((objId.length()>0)?(objId[objId.length()-1] == '*'):0)) { // handle a multicast to several objects. // doesn't handle proxies currently. should it? TQPtrList matchList = diff --git a/dcop/dcopserver.cpp b/dcop/dcopserver.cpp index ef37f0a32..c78664f9a 100644 --- a/dcop/dcopserver.cpp +++ b/dcop/dcopserver.cpp @@ -127,7 +127,7 @@ static TQCString readQCString(TQDataStream &ds) TQ_UINT32 len; ds >> len; TQIODevice *device = ds.tqdevice(); - int bytesLeft = device->size()-device->at(); + int bytesLeft = device->size()-device->tqat(); if ((bytesLeft < 0 ) || (len > (uint) bytesLeft)) { qWarning("Corrupt data!\n"); @@ -146,7 +146,7 @@ static TQByteArray readQByteArray(TQDataStream &ds) TQ_UINT32 len; ds >> len; TQIODevice *device = ds.tqdevice(); - int bytesLeft = device->size()-device->at(); + int bytesLeft = device->size()-device->tqat(); if ((bytesLeft < 0 ) || (len > (uint) bytesLeft)) { qWarning("Corrupt data!\n"); -- cgit v1.2.1