summaryrefslogtreecommitdiffstats
path: root/src/sources/acpithermalsrc.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-04 20:48:23 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-04 20:48:23 +0000
commit383adc283801b6238d8acfc750890613a63f8060 (patch)
treeaf3a65389067c05263db2ef4551a541501422998 /src/sources/acpithermalsrc.cpp
parentda7847adb43726079c7a4be1f06acbebe0bdde57 (diff)
downloadkima-383adc283801b6238d8acfc750890613a63f8060.tar.gz
kima-383adc283801b6238d8acfc750890613a63f8060.zip
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
Diffstat (limited to 'src/sources/acpithermalsrc.cpp')
-rw-r--r--src/sources/acpithermalsrc.cpp24
1 files changed, 12 insertions, 12 deletions
diff --git a/src/sources/acpithermalsrc.cpp b/src/sources/acpithermalsrc.cpp
index fdc0260..f762d00 100644
--- a/src/sources/acpithermalsrc.cpp
+++ b/src/sources/acpithermalsrc.cpp
@@ -19,15 +19,15 @@
***************************************************************************/
#include "acpithermalsrc.h"
-#include <qtextstream.h>
-#include <qdir.h>
+#include <tqtextstream.h>
+#include <tqdir.h>
#include <klocale.h>
-ACPIThermalSrc::ACPIThermalSrc(QWidget* inParent, const QFile& inSourceFile):
+ACPIThermalSrc::ACPIThermalSrc(TQWidget* inParent, const TQFile& inSourceFile):
LabelSource(inParent),
mSourceFile(inSourceFile.name()),
mTrigger(this){
- mID = mSourceFile.name().section('/', -2, -2, QString::SectionSkipEmpty);
+ mID = mSourceFile.name().section('/', -2, -2, TQString::SectionSkipEmpty);
mName = mID;
mDescription = i18n("This source is provided by the Linux ACPI Thermal Zone driver.");
}
@@ -35,15 +35,15 @@ ACPIThermalSrc::ACPIThermalSrc(QWidget* inParent, const QFile& inSourceFile):
ACPIThermalSrc::~ACPIThermalSrc(){
}
-std::list<Source*>ACPIThermalSrc::createInstances(QWidget* inParent){
+std::list<Source*>ACPIThermalSrc::createInstances(TQWidget* inParent){
std::list<Source*> list;
- QDir d( "/proc/acpi/thermal_zone" );
+ TQDir d( "/proc/acpi/thermal_zone" );
if( d.exists() ){
- d.setFilter( QDir::Dirs | QDir::NoSymLinks );
- d.setSorting( QDir::Name);
+ d.setFilter( TQDir::Dirs | TQDir::NoSymLinks );
+ d.setSorting( TQDir::Name);
for( unsigned int i = 0; i < d.count(); i++ ){
if((d[i] != ".") && (d[i] != "..")){
- QFile acpiFile(d.canonicalPath() + "/" + d[i] + "/temperature");
+ TQFile acpiFile(d.canonicalPath() + "/" + d[i] + "/temperature");
list.push_back(new ACPIThermalSrc(inParent, acpiFile));
}
}
@@ -51,10 +51,10 @@ std::list<Source*>ACPIThermalSrc::createInstances(QWidget* inParent){
return list;
}
-QString ACPIThermalSrc::fetchValue() {
- QString s = "n/a";
+TQString ACPIThermalSrc::fetchValue() {
+ TQString s = "n/a";
if(mSourceFile.open(IO_ReadOnly)){
- QTextStream textStream(&mSourceFile);
+ TQTextStream textStream(&mSourceFile);
s = textStream.readLine();
mSourceFile.close();
s = s.remove("temperature:").stripWhiteSpace();