From 383adc283801b6238d8acfc750890613a63f8060 Mon Sep 17 00:00:00 2001 From: tpearson Date: Mon, 4 Jul 2011 20:48:23 +0000 Subject: TQt4 port kima This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kima@1239290 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- src/cpufreqd/cpufreqd.cpp | 38 +++++++++++++++++++------------------- 1 file changed, 19 insertions(+), 19 deletions(-) (limited to 'src/cpufreqd/cpufreqd.cpp') diff --git a/src/cpufreqd/cpufreqd.cpp b/src/cpufreqd/cpufreqd.cpp index 833db29..b5f1ad0 100644 --- a/src/cpufreqd/cpufreqd.cpp +++ b/src/cpufreqd/cpufreqd.cpp @@ -19,9 +19,9 @@ ***************************************************************************/ #include "cpufreqd.h" -#include -#include -#include +#include +#include +#include #include #define CHUNK_SIZE 4096 @@ -35,22 +35,22 @@ */ CPUFreqd::CPUFreqd() { - m_menu = new QPopupMenu(); - QObject::connect(m_menu, SIGNAL(aboutToShow()), this, SLOT(updateMenu())); + m_menu = new TQPopupMenu(); + TQObject::connect(m_menu, TQT_SIGNAL(aboutToShow()), this, TQT_SLOT(updateMenu())); - m_dynamic = new QAction(i18n("Select dynamically"), QKeySequence(), this); - QObject::connect(m_dynamic, SIGNAL(activated()), this, SLOT(setDynamic())); + m_dynamic = new TQAction(i18n("Select dynamically"), TQKeySequence(), this); + TQObject::connect(m_dynamic, TQT_SIGNAL(activated()), this, TQT_SLOT(setDynamic())); m_dynamic->setToggleAction(true); m_dynamic->setOn(true); - m_items = new QActionGroup(this); + m_items = new TQActionGroup(this); m_items->setExclusive(true); - m_actions = new QPtrList(); + m_actions = new TQPtrList(); m_actions->setAutoDelete(true); - m_mapper = new QSignalMapper(this); - QObject::connect(m_mapper, SIGNAL(mapped(int)), this, SLOT(setProfile(int))); + m_mapper = new TQSignalMapper(this); + TQObject::connect(m_mapper, TQT_SIGNAL(mapped(int)), this, TQT_SLOT(setProfile(int))); } CPUFreqd::~CPUFreqd() { @@ -60,9 +60,9 @@ bool CPUFreqd::enabled() const { return m_conn.available(); } -QValueVector & CPUFreqd::getProfiles(bool reconnect) { +TQValueVector & CPUFreqd::getProfiles(bool reconnect) { char chunk[CHUNK_SIZE]; - QString buffer; + TQString buffer; if (!m_profiles.empty()) m_profiles.clear(); @@ -84,8 +84,8 @@ QValueVector & CPUFreqd::getProfiles(bool reconnect) { buffer.append(chunk); } - QStringList profiles = QStringList::split("\n", buffer); - for (QStringList::Iterator it = profiles.begin(); it != profiles.end(); it++) + TQStringList profiles = TQStringList::split("\n", buffer); + for (TQStringList::Iterator it = profiles.begin(); it != profiles.end(); it++) m_profiles.push_back( CPUFreqdProfile(*it) ); m_conn.close(); @@ -93,12 +93,12 @@ QValueVector & CPUFreqd::getProfiles(bool reconnect) { return m_profiles; } -QPopupMenu* CPUFreqd::menu() { +TQPopupMenu* CPUFreqd::menu() { return m_menu; } void CPUFreqd::updateMenu() { - QAction *cur; + TQAction *cur; m_menu->clear(); m_actions->clear(); @@ -110,8 +110,8 @@ void CPUFreqd::updateMenu() { for (unsigned int i = 0; i < m_profiles.count(); i++) if (m_profiles[i].isValid()) { - cur = new QAction(m_profiles[i].name(), QKeySequence(), m_items); - QObject::connect(cur, SIGNAL(activated()), m_mapper, SLOT(map())); + cur = new TQAction(m_profiles[i].name(), TQKeySequence(), m_items); + TQObject::connect(cur, TQT_SIGNAL(activated()), m_mapper, TQT_SLOT(map())); cur->setToggleAction(true); cur->setOn(m_profiles[i].active()); -- cgit v1.2.1