summaryrefslogtreecommitdiffstats
path: root/libktorrent/torrent/udptracker.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 20:34:15 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-28 20:34:15 +0000
commit1c1403293485f35fd53db45aaa77a01cdd9627e7 (patch)
tree38559cd68cd4f63023fb5f6375def9db3b8b491e /libktorrent/torrent/udptracker.cpp
parent894f94545727610df22c4f73911d62d58266f695 (diff)
downloadktorrent-1c1403293485f35fd53db45aaa77a01cdd9627e7.tar.gz
ktorrent-1c1403293485f35fd53db45aaa77a01cdd9627e7.zip
TQt4 port ktorrent
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/ktorrent@1238733 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libktorrent/torrent/udptracker.cpp')
-rw-r--r--libktorrent/torrent/udptracker.cpp34
1 files changed, 17 insertions, 17 deletions
diff --git a/libktorrent/torrent/udptracker.cpp b/libktorrent/torrent/udptracker.cpp
index 2dd4a01..6597349 100644
--- a/libktorrent/torrent/udptracker.cpp
+++ b/libktorrent/torrent/udptracker.cpp
@@ -51,16 +51,16 @@ namespace bt
transaction_id = 0;
interval = 0;
- connect(&conn_timer,SIGNAL(timeout()),this,SLOT(onConnTimeout()));
- connect(socket,SIGNAL(announceRecieved(Int32, const QByteArray &)),
- this,SLOT(announceRecieved(Int32, const QByteArray& )));
- connect(socket,SIGNAL(connectRecieved(Int32, Int64 )),
- this,SLOT(connectRecieved(Int32, Int64 )));
- connect(socket,SIGNAL(error(Int32, const QString& )),
- this,SLOT(onError(Int32, const QString& )));
+ connect(&conn_timer,TQT_SIGNAL(timeout()),this,TQT_SLOT(onConnTimeout()));
+ connect(socket,TQT_SIGNAL(announceRecieved(Int32, const TQByteArray &)),
+ this,TQT_SLOT(announceRecieved(Int32, const TQByteArray& )));
+ connect(socket,TQT_SIGNAL(connectRecieved(Int32, Int64 )),
+ this,TQT_SLOT(connectRecieved(Int32, Int64 )));
+ connect(socket,TQT_SIGNAL(error(Int32, const TQString& )),
+ this,TQT_SLOT(onError(Int32, const TQString& )));
- KResolver::resolveAsync(this,SLOT(onResolverResults(KResolverResults )),
- url.host(),QString::number(url.port()));
+ KResolver::resolveAsync(this,TQT_SLOT(onResolverResults(KResolverResults )),
+ url.host(),TQString::number(url.port()));
}
@@ -117,7 +117,7 @@ namespace bt
sendAnnounce();
}
- void UDPTracker::announceRecieved(Int32 tid,const QByteArray & data)
+ void UDPTracker::announceRecieved(Int32 tid,const TQByteArray & data)
{
if (tid != transaction_id)
return;
@@ -143,11 +143,11 @@ namespace bt
for (Uint32 i = 20;i < data.size() && j < nip;i+=6,j++)
{
Uint32 ip = ReadUint32(buf,i);
- addPeer(QString("%1.%2.%3.%4")
- .arg((ip & (0xFF000000)) >> 24)
- .arg((ip & (0x00FF0000)) >> 16)
- .arg((ip & (0x0000FF00)) >> 8)
- .arg(ip & 0x000000FF),
+ addPeer(TQString("%1.%2.%3.%4")
+ .tqarg((ip & (0xFF000000)) >> 24)
+ .tqarg((ip & (0x00FF0000)) >> 16)
+ .tqarg((ip & (0x0000FF00)) >> 8)
+ .tqarg(ip & 0x000000FF),
ReadUint16(buf,i+4));
}
@@ -168,7 +168,7 @@ namespace bt
}
}
- void UDPTracker::onError(Int32 tid,const QString & error_string)
+ void UDPTracker::onError(Int32 tid,const TQString & error_string)
{
if (tid != transaction_id)
return;
@@ -245,7 +245,7 @@ namespace bt
WriteInt64(buf,64,s.bytes_left);
WriteInt64(buf,72,s.trk_bytes_uploaded);
WriteInt32(buf,80,ev);
- QString cip = Tracker::getCustomIP();
+ TQString cip = Tracker::getCustomIP();
if (cip.isNull())
{
WriteUint32(buf,84,0);