summaryrefslogtreecommitdiffstats
path: root/kicker/applets/naughty
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-19 01:42:14 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-01-19 01:42:14 +0000
commit8155225c9be993acc0512956416d195edfef4eb9 (patch)
treede4f3cd17614fc67e47eefabcdbe2fbe170c9be7 /kicker/applets/naughty
parent364641b8e0279758d236af39abd138d379328a19 (diff)
downloadtdebase-8155225c9be993acc0512956416d195edfef4eb9.tar.gz
tdebase-8155225c9be993acc0512956416d195edfef4eb9.zip
Enable compilation with TQt for Qt4 3.4.0 TP2
This should not break compatibility with TQt for Qt3; if it does please fix it ASAP! git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdebase@1215552 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kicker/applets/naughty')
-rw-r--r--kicker/applets/naughty/NaughtyApplet.cpp4
-rw-r--r--kicker/applets/naughty/NaughtyConfigDialog.cpp2
-rw-r--r--kicker/applets/naughty/NaughtyProcessMonitor.cpp22
-rw-r--r--kicker/applets/naughty/NaughtyProcessMonitor.h2
4 files changed, 15 insertions, 15 deletions
diff --git a/kicker/applets/naughty/NaughtyApplet.cpp b/kicker/applets/naughty/NaughtyApplet.cpp
index 44f2229ec..05a64b94b 100644
--- a/kicker/applets/naughty/NaughtyApplet.cpp
+++ b/kicker/applets/naughty/NaughtyApplet.cpp
@@ -72,7 +72,7 @@ NaughtyApplet::NaughtyApplet
TQVBoxLayout * layout = new TQVBoxLayout(this);
layout->addWidget(button_);
- monitor_ = new NaughtyProcessMonitor(2, 20, this);
+ monitor_ = new NaughtyProcessMonitor(2, 20, TQT_TQOBJECT(this));
connect
(
@@ -105,7 +105,7 @@ NaughtyApplet::~NaughtyApplet()
void
NaughtyApplet::slotWarn(ulong pid, const TQString & name)
{
- if (ignoreList_.contains(name))
+ if (ignoreList_.tqcontains(name))
return;
TQString s = i18n("A program called '%1' is slowing down the others "
diff --git a/kicker/applets/naughty/NaughtyConfigDialog.cpp b/kicker/applets/naughty/NaughtyConfigDialog.cpp
index 57146778d..8b6948a04 100644
--- a/kicker/applets/naughty/NaughtyConfigDialog.cpp
+++ b/kicker/applets/naughty/NaughtyConfigDialog.cpp
@@ -85,7 +85,7 @@ NaughtyConfigDialog::threshold() const
return uint(kini_threshold_->value());
}
- QStringList
+ TQStringList
NaughtyConfigDialog::ignoreList() const
{
TQStringList retval;
diff --git a/kicker/applets/naughty/NaughtyProcessMonitor.cpp b/kicker/applets/naughty/NaughtyProcessMonitor.cpp
index 6228cfba1..e8cdaf60f 100644
--- a/kicker/applets/naughty/NaughtyProcessMonitor.cpp
+++ b/kicker/applets/naughty/NaughtyProcessMonitor.cpp
@@ -164,7 +164,7 @@ NaughtyProcessMonitor::slotTimeout()
void
NaughtyProcessMonitor::_process(ulong pid, uint load)
{
- if (!d->loadMap_.contains(pid))
+ if (!d->loadMap_.tqcontains(pid))
{
d->loadMap_.insert(pid, load);
return;
@@ -172,12 +172,12 @@ NaughtyProcessMonitor::_process(ulong pid, uint load)
uint oldLoad = d->loadMap_[pid];
bool misbehaving = (load - oldLoad) > 40 * (d->interval_ / 1000);
- bool wasMisbehaving = d->scoreMap_.contains(pid);
+ bool wasMisbehaving = d->scoreMap_.tqcontains(pid);
if (misbehaving)
if (wasMisbehaving)
{
- d->scoreMap_.replace(pid, d->scoreMap_[pid] + 1);
+ d->scoreMap_.tqreplace(pid, d->scoreMap_[pid] + 1);
if (canKill(pid))
emit(runawayProcess(pid, processName(pid)));
}
@@ -187,7 +187,7 @@ NaughtyProcessMonitor::_process(ulong pid, uint load)
if (wasMisbehaving)
d->scoreMap_.remove(pid);
- d->loadMap_.replace(pid, load);
+ d->loadMap_.tqreplace(pid, load);
}
// Here begins the set of system-specific methods.
@@ -221,7 +221,7 @@ NaughtyProcessMonitor::canKill(ulong pid) const
return geteuid() == a;
#elif defined(__OpenBSD__)
// simply check if entry exists in the uid map and use it
- if (!d->uidMap_.contains(pid))
+ if (!d->uidMap_.tqcontains(pid))
return false ;
return geteuid () == d->uidMap_[pid] ;
@@ -231,7 +231,7 @@ NaughtyProcessMonitor::canKill(ulong pid) const
#endif
}
- QString
+ TQString
NaughtyProcessMonitor::processName(ulong pid) const
{
#if defined(__linux__) || defined(__OpenBSD__)
@@ -255,7 +255,7 @@ NaughtyProcessMonitor::processName(ulong pid) const
}
// Now strip 'kdeinit:' prefix.
- TQString unicode(TQString::fromLocal8Bit(s));
+ TQString tqunicode(TQString::fromLocal8Bit(s));
#elif defined(__OpenBSD__)
int mib[4] ;
@@ -280,16 +280,16 @@ NaughtyProcessMonitor::processName(ulong pid) const
}
// Now strip 'kdeinit:' prefix.
- TQString unicode(TQString::fromLocal8Bit(argv[0]));
+ TQString tqunicode(TQString::fromLocal8Bit(argv[0]));
free (argv) ;
#endif
- TQStringList parts(TQStringList::split(' ', unicode));
+ TQStringList parts(TQStringList::split(' ', tqunicode));
TQString processName = parts[0] == "kdeinit:" ? parts[1] : parts[0];
- int lastSlash = processName.findRev('/');
+ int lastSlash = processName.tqfindRev('/');
// Get basename, if there's a path.
if (-1 != lastSlash)
@@ -449,7 +449,7 @@ NaughtyProcessMonitor::getLoad(ulong pid, uint & load) const
return true;
#elif defined(__OpenBSD__)
// use cache
- if (!d->cacheLoadMap_.contains(pid))
+ if (!d->cacheLoadMap_.tqcontains(pid))
return false ;
load = d->cacheLoadMap_[pid] ;
diff --git a/kicker/applets/naughty/NaughtyProcessMonitor.h b/kicker/applets/naughty/NaughtyProcessMonitor.h
index cc5c91cfc..c21cb393b 100644
--- a/kicker/applets/naughty/NaughtyProcessMonitor.h
+++ b/kicker/applets/naughty/NaughtyProcessMonitor.h
@@ -25,7 +25,7 @@
class NaughtyProcessMonitorPrivate;
-class NaughtyProcessMonitor : public QObject
+class NaughtyProcessMonitor : public TQObject
{
Q_OBJECT