summaryrefslogtreecommitdiffstats
path: root/src/modules/torrent/tc_statusbarapplet.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/torrent/tc_statusbarapplet.cpp')
-rw-r--r--src/modules/torrent/tc_statusbarapplet.cpp30
1 files changed, 15 insertions, 15 deletions
diff --git a/src/modules/torrent/tc_statusbarapplet.cpp b/src/modules/torrent/tc_statusbarapplet.cpp
index 5d23a29..b609e8d 100644
--- a/src/modules/torrent/tc_statusbarapplet.cpp
+++ b/src/modules/torrent/tc_statusbarapplet.cpp
@@ -1,14 +1,14 @@
-#include "qtimer.h"
+#include "tqtimer.h"
#include "kvi_locale.h"
#include "kvi_iconmanager.h"
#include "tc_interface.h"
#include "tc_statusbarapplet.h"
-KviTorrentStatusBarApplet::KviTorrentStatusBarApplet(KviStatusBar *parent, KviStatusBarAppletDescriptor *desc)
- : KviStatusBarApplet(parent, desc)
+KviTorrentStatusBarApplet::KviTorrentStatusBarApplet(KviStatusBar *tqparent, KviStatusBarAppletDescriptor *desc)
+ : KviStatusBarApplet(tqparent, desc)
{
- QTimer *timer = new QTimer(this);
- connect(timer, SIGNAL(timeout()), this, SLOT(update()));
+ TQTimer *timer = new TQTimer(this);
+ connect(timer, TQT_SIGNAL(timeout()), this, TQT_SLOT(update()));
timer->start(250, FALSE);
// updateDisplay();
//
@@ -36,26 +36,26 @@ void KviTorrentStatusBarApplet::selfRegister(KviStatusBar *bar)
bar->registerAppletDescriptor(d);
}
-QString formatSize(float sz)
+TQString formatSize(float sz)
{
if (sz >= 1024.0f*1024.0f*1024.0f)
- return QString("%1 GB").arg(sz / (1024.0f*1024.0f*1024.0f), 2, 'f', 2);
+ return TQString("%1 GB").tqarg(sz / (1024.0f*1024.0f*1024.0f), 2, 'f', 2);
if (sz >= 1024.0f*1024.0f)
- return QString("%1 MB").arg(sz / (1024.0f*1024.0f), 2, 'f', 2);
+ return TQString("%1 MB").tqarg(sz / (1024.0f*1024.0f), 2, 'f', 2);
if (sz >= 1024.0f)
- return QString("%1 KB").arg(sz / 1024.0f, 2, 'f', 2);
- return QString("%1 B").arg(sz, 2, 'f', 2);
+ return TQString("%1 KB").tqarg(sz / 1024.0f, 2, 'f', 2);
+ return TQString("%1 B").tqarg(sz, 2, 'f', 2);
}
void KviTorrentStatusBarApplet::update()
{
if (KviTorrentInterface::selected())
{
- QString msg = QString("up: %1 K/s (%2), dn: %3 K/s (%4)")
- .arg(KviTorrentInterface::selected()->speedUp(), 2)
- .arg(formatSize(KviTorrentInterface::selected()->trafficUp()))
- .arg(KviTorrentInterface::selected()->speedDown(), 2)
- .arg(formatSize(KviTorrentInterface::selected()->trafficDown()));
+ TQString msg = TQString("up: %1 K/s (%2), dn: %3 K/s (%4)")
+ .tqarg(KviTorrentInterface::selected()->speedUp(), 2)
+ .tqarg(formatSize(KviTorrentInterface::selected()->trafficUp()))
+ .tqarg(KviTorrentInterface::selected()->speedDown(), 2)
+ .tqarg(formatSize(KviTorrentInterface::selected()->trafficDown()));
setText(msg);