summaryrefslogtreecommitdiffstats
path: root/src/kbtransferfile.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/kbtransferfile.cpp')
-rw-r--r--src/kbtransferfile.cpp48
1 files changed, 24 insertions, 24 deletions
diff --git a/src/kbtransferfile.cpp b/src/kbtransferfile.cpp
index d8e158e..b55ba1b 100644
--- a/src/kbtransferfile.cpp
+++ b/src/kbtransferfile.cpp
@@ -23,25 +23,25 @@
#define _LARGEFILE_SOURCE
#define _LARGEFILE64_SOURCE
-#include <qpainter.h>
-#include <qcolor.h>
+#include <ntqpainter.h>
+#include <ntqcolor.h>
#include "kbstatustip.h"
#include "kbsiteinfo.h"
#include "kbtransferfile.h"
-KbTransferFile::KbTransferFile(QListView *taskview, QListViewItem *after, FtpSession *srcsession, FtpSession *dstsession, KbFileInfo *src, KbFileInfo *dst) : KbTransferItem(taskview, after, srcsession, dstsession, src, dst)
+KbTransferFile::KbTransferFile(TQListView *taskview, TQListViewItem *after, FtpSession *srcsession, FtpSession *dstsession, KbFileInfo *src, KbFileInfo *dst) : KbTransferItem(taskview, after, srcsession, dstsession, src, dst)
{
- setPixmap(0, KGlobal::iconLoader()->loadIcon("files",KIcon::Small));
+ setPixmap(0, TDEGlobal::iconLoader()->loadIcon("files",TDEIcon::Small));
m_time_old = -1;
m_xfered_old = 0;
m_percentage = 0;
}
-KbTransferFile::KbTransferFile(QListViewItem *root, QListViewItem *after, FtpSession *srcsession, FtpSession *dstsession, KbFileInfo *src, KbFileInfo *dst) : KbTransferItem(root, after, srcsession, dstsession, src, dst)
+KbTransferFile::KbTransferFile(TQListViewItem *root, TQListViewItem *after, FtpSession *srcsession, FtpSession *dstsession, KbFileInfo *src, KbFileInfo *dst) : KbTransferItem(root, after, srcsession, dstsession, src, dst)
{
- setPixmap(0, KGlobal::iconLoader()->loadIcon("files",KIcon::Small));
+ setPixmap(0, TDEGlobal::iconLoader()->loadIcon("files",TDEIcon::Small));
m_time_old = -1;
m_xfered_old = 0;
}
@@ -57,11 +57,11 @@ int KbTransferFile::rtti() const
void KbTransferFile::Info()
{
- qWarning("INFO: transfer file from %s to %s", mp_srcsession->name(), mp_dstsession->name());
- qWarning("INFO: mp_src->fileName() = %s", mp_src->fileName().latin1());
- qWarning("INFO: mp_dst->fileName() = %s", mp_dst->fileName().latin1());
- qWarning("INFO: mp_src->dirPath() = %s", mp_src->dirPath(true).latin1());
- qWarning("INFO: mp_dst->dirPath() = %s", mp_dst->dirPath(true).latin1());
+ tqWarning("INFO: transfer file from %s to %s", mp_srcsession->name(), mp_dstsession->name());
+ tqWarning("INFO: mp_src->fileName() = %s", mp_src->fileName().latin1());
+ tqWarning("INFO: mp_dst->fileName() = %s", mp_dst->fileName().latin1());
+ tqWarning("INFO: mp_src->dirPath() = %s", mp_src->dirPath(true).latin1());
+ tqWarning("INFO: mp_dst->dirPath() = %s", mp_dst->dirPath(true).latin1());
}
void KbTransferFile::ShowProgress(KbStatusTip *statustip)
@@ -80,41 +80,41 @@ void KbTransferFile::ShowProgress(KbStatusTip *statustip)
if ((mp_srcsession->Connected()) && (mp_dstsession->Connected()))
{
- setText(1, "unknown kb of " + QString::number(wholesize) + "kb");
+ setText(1, "unknown kb of " + TQString::number(wholesize) + "kb");
setText(2, "unknown kb/s");
setText(4, "unknown");
}
else
{
- setText(1, QString::number(currentsize) + "kb of " + QString::number(wholesize) + "kb");
- setText(2, QString::number(speed) + "kb/s");
- setText(4, QString::number(remaining / 3600) + "h" + QString::number(remaining / 60) + "m" + QString::number(remaining % 60) + "s");
+ setText(1, TQString::number(currentsize) + "kb of " + TQString::number(wholesize) + "kb");
+ setText(2, TQString::number(speed) + "kb/s");
+ setText(4, TQString::number(remaining / 3600) + "h" + TQString::number(remaining / 60) + "m" + TQString::number(remaining % 60) + "s");
}
m_time_old = time;
m_xfered_old = m_xfered;
statustip->ShowStatus(mp_src->fileName()
- + "," + QString::number(m_percentage) + "%," + QString::number(speed) + "kb/s");
+ + "," + TQString::number(m_percentage) + "%," + TQString::number(speed) + "kb/s");
- //QToolTip::add(systemtray, mp_src->fileName()
- //+ "," + QString::number(percentage) + "%," + QString::number(speed) + "kb/s");
+ //TQToolTip::add(systemtray, mp_src->fileName()
+ //+ "," + TQString::number(percentage) + "%," + TQString::number(speed) + "kb/s");
}
-void KbTransferFile::paintCell( QPainter *painter, const QColorGroup &colorGroup, int column,
+void KbTransferFile::paintCell( TQPainter *painter, const TQColorGroup &colorGroup, int column,
int width, int alignment )
{
if ((column == 3)
&& (m_xfered_old != 0)
&& ((!mp_srcsession->Connected()) || (!mp_dstsession->Connected())))
PaintPercentageBar (painter, width);
- else QListViewItem::paintCell(painter, colorGroup, column, width, alignment);
+ else TQListViewItem::paintCell(painter, colorGroup, column, width, alignment);
}
-void KbTransferFile::PaintPercentageBar(QPainter * painter, int width)
+void KbTransferFile::PaintPercentageBar(TQPainter * painter, int width)
{
int len = width * m_percentage / 100;
- painter->fillRect(0, 0, width, height(), Qt::lightGray);
- painter->fillRect(0, 0, len, height(), Qt::gray);
- painter->drawText((width / 2) - 10, height() - 5, QString::number(m_percentage) + "%");
+ painter->fillRect(0, 0, width, height(), TQt::lightGray);
+ painter->fillRect(0, 0, len, height(), TQt::gray);
+ painter->drawText((width / 2) - 10, height() - 5, TQString::number(m_percentage) + "%");
}