summaryrefslogtreecommitdiffstats
path: root/kfilereplace/commandengine.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'kfilereplace/commandengine.cpp')
-rw-r--r--kfilereplace/commandengine.cpp26
1 files changed, 13 insertions, 13 deletions
diff --git a/kfilereplace/commandengine.cpp b/kfilereplace/commandengine.cpp
index ffb1919d..aaf40f38 100644
--- a/kfilereplace/commandengine.cpp
+++ b/kfilereplace/commandengine.cpp
@@ -34,10 +34,10 @@ TQString CommandEngine::datetime(const TQString& opt, const TQString& arg)
{
Q_UNUSED(arg);
if(opt == "iso")
- return TQDateTime::currentDateTime(Qt::LocalTime).toString(Qt::ISODate);
+ return TQDateTime::tqcurrentDateTime(Qt::LocalTime).toString(Qt::ISODate);
if(opt == "local")
- return TQDateTime::currentDateTime(Qt::LocalTime).toString(Qt::LocalDate);
- return TQString::null;
+ return TQDateTime::tqcurrentDateTime(Qt::LocalTime).toString(Qt::LocalDate);
+ return TQString();
}
TQString CommandEngine::user(const TQString& opt, const TQString& arg)
@@ -56,7 +56,7 @@ TQString CommandEngine::user(const TQString& opt, const TQString& arg)
return u.homeDir();
if(opt == "shell")
return u.shell();
- return TQString::null;
+ return TQString();
}
TQString CommandEngine::loadfile(const TQString& opt, const TQString& arg)
@@ -64,7 +64,7 @@ TQString CommandEngine::loadfile(const TQString& opt, const TQString& arg)
Q_UNUSED(arg);
TQFile f(opt);
- if(!f.open(IO_ReadOnly)) return TQString::null;
+ if(!f.open(IO_ReadOnly)) return TQString();
TQTextStream t(&f);
@@ -89,11 +89,11 @@ TQString CommandEngine::mathexp(const TQString& opt, const TQString& arg)
Q_UNUSED(arg);
TQString tempOpt = opt;
- tempOpt.replace("ln","l");
- tempOpt.replace("sin","s");
- tempOpt.replace("cos","c");
- tempOpt.replace("arctan","a");
- tempOpt.replace("exp","e");
+ tempOpt.tqreplace("ln","l");
+ tempOpt.tqreplace("sin","s");
+ tempOpt.tqreplace("cos","c");
+ tempOpt.tqreplace("arctan","a");
+ tempOpt.tqreplace("exp","e");
TQString program = "var=("+tempOpt+");print var";
TQString script = "echo '"+program+"' | bc -l;";
@@ -111,7 +111,7 @@ TQString CommandEngine::mathexp(const TQString& opt, const TQString& arg)
//Through slotGetScriptOutput, m_processOutput contains the result of the KProcess call
if(!proc->start(KProcess::Block, KProcess::All))
{
- return TQString::null;
+ return TQString();
}
else
{
@@ -121,7 +121,7 @@ TQString CommandEngine::mathexp(const TQString& opt, const TQString& arg)
delete proc;
TQString tempbuf = m_processOutput;
- m_processOutput = TQString::null;
+ m_processOutput = TQString();
return tempbuf;
@@ -156,7 +156,7 @@ TQString CommandEngine::variableValue(const TQString &variable)
s.remove("[$").remove("$]").remove(" ");
- if(s.contains(":") == 0)
+ if(s.tqcontains(":") == 0)
return variable;
else
{