From 7c2bc4b5ce4fc1a72868aa949e9ec49fbe2e7931 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sl=C3=A1vek=20Banko?= Date: Sat, 27 Jul 2013 16:57:53 +0200 Subject: Initial TQt conversion --- src/trayicon.cpp | 44 ++++++++++++++++++++++---------------------- 1 file changed, 22 insertions(+), 22 deletions(-) (limited to 'src/trayicon.cpp') diff --git a/src/trayicon.cpp b/src/trayicon.cpp index 5517def..4422bf0 100644 --- a/src/trayicon.cpp +++ b/src/trayicon.cpp @@ -47,9 +47,9 @@ #include #include #include "trayicon.h" -#include +#include #include -#include +#include #include "trayhoverpopup.h" #include "torkconfig.h" @@ -59,7 +59,7 @@ TrayIcon::TrayIcon( tork *parent, const char *name) { m_kt_pix = loadIcon("tork"); setPixmap(m_kt_pix); - paint=new QPainter( this ); + paint=new TQPainter( this ); drawContents ( paint ); m_parent = parent; @@ -75,15 +75,15 @@ TrayIcon::TrayIcon( tork *parent, const char *name) TrayIcon::~TrayIcon() {} -void TrayIcon::dragEnterEvent(QDragEnterEvent *e) +void TrayIcon::dragEnterEvent(TQDragEnterEvent *e) { e->accept (KURLDrag::canDecode(e)); } -void TrayIcon::dropEvent (QDropEvent *o) +void TrayIcon::dropEvent (TQDropEvent *o) { KURL::List list; - QString text; + TQString text; if ( KURLDrag::decode( o, list ) ) droppedfile(list); } @@ -98,34 +98,34 @@ void TrayIcon::droppedfile (KURL::List url) } -void TrayIcon::enterEvent(QEvent* ev) +void TrayIcon::enterEvent(TQEvent* ev) { KSystemTray::enterEvent(ev); m_hover_popup->enterEvent(); } -void TrayIcon::leaveEvent(QEvent* ) +void TrayIcon::leaveEvent(TQEvent* ) { m_hover_popup->leaveEvent(); } -void TrayIcon::updateStats(const QString & downloadBandwidthHist, - const QString & uploadBandwidthHist, - const QString & downloadBandwidth, const QString & uploadBandwidth, - const QStringList & serverReport, const QStringList & clientReport, - const QString & curBandwidthRate) +void TrayIcon::updateStats(const TQString & downloadBandwidthHist, + const TQString & uploadBandwidthHist, + const TQString & downloadBandwidth, const TQString & uploadBandwidth, + const TQStringList & serverReport, const TQStringList & clientReport, + const TQString & curBandwidthRate) { - QString serverStatus; - for ( QStringList::ConstIterator it = serverReport.begin(); it != serverReport.end(); ++it ) + TQString serverStatus; + for ( TQStringList::ConstIterator it = serverReport.begin(); it != serverReport.end(); ++it ) { if ((*it).isEmpty()) continue; if ((it) != serverReport.begin()) - serverStatus.append(QString("%1").arg((*it))); + serverStatus.append(TQString("%1").arg((*it))); } - QString tip = i18n("" + TQString tip = i18n("
" "" "" "" @@ -202,7 +202,7 @@ void SetMaxRate::makeMenu() for (int i = 0; i < 15; i++) { - QValueList valuePair; + TQValueList valuePair; if (delta == 0) valuePair.append(maxBandwidth); else @@ -225,10 +225,10 @@ void SetMaxRate::makeMenu() { if(m_rate == valuePair[j] && j==0) { - setItemChecked(insertItem(QString("%1 KB/s").arg(valuePair[j]),-1, (j == 0) ? 2 : (int)count()), true); + setItemChecked(insertItem(TQString("%1 KB/s").arg(valuePair[j]),-1, (j == 0) ? 2 : (int)count()), true); } else - insertItem(QString("%1 KB/s").arg(valuePair[j]),-1, (j == 0) ? 2 : (int)count()); + insertItem(TQString("%1 KB/s").arg(valuePair[j]),-1, (j == 0) ? 2 : (int)count()); } } @@ -249,8 +249,8 @@ void SetMaxRate::rateSelected(int id) // kdDebug() << text(id) << endl; // kdDebug() << text(id).toInt() << endl; - //QT Bug: The value referenced by the QPopUpMenu ID often has an ampersand - QString textID = text(id); + //QT Bug: The value referenced by the TQPopUpMenu ID often has an ampersand + TQString textID = text(id); textID.replace("&",""); textID.replace(" KB/s",""); -- cgit v1.2.1
Client:%1