From a1bd60b34891ccc77056c190d7871bc4b14fe654 Mon Sep 17 00:00:00 2001 From: tpearson Date: Wed, 22 Jun 2011 21:31:21 +0000 Subject: TQt4 port kdetoys This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdetoys@1238103 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- kweather/weatherlib.cpp | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'kweather/weatherlib.cpp') diff --git a/kweather/weatherlib.cpp b/kweather/weatherlib.cpp index c06e89a..1fee670 100644 --- a/kweather/weatherlib.cpp +++ b/kweather/weatherlib.cpp @@ -65,7 +65,7 @@ WeatherLib::Data::Data() void WeatherLib::Data::clear() { - age = TQDateTime::currentDateTime(); + age = TQDateTime::tqcurrentDateTime(); downloading = false; updated = false; job = 0; @@ -77,8 +77,8 @@ void WeatherLib::Data::clear() } } -WeatherLib::WeatherLib(StationDatabase *stationDB, TQObject *parent, const char *name) - : TQObject (parent, name) +WeatherLib::WeatherLib(StationDatabase *stationDB, TQObject *tqparent, const char *name) + : TQObject (tqparent, name) { KGlobal::locale()->insertCatalogue("kweather"); @@ -124,7 +124,7 @@ void WeatherLib::slotCopyDone(KIO::Job* job) //TQTextStream *t = d->target->textStream(); if( t ) { - TQString s = TQString::null; + TQString s = TQString(); while ( !t->eof() ) { s += " " + t->readLine(); @@ -135,7 +135,7 @@ void WeatherLib::slotCopyDone(KIO::Job* job) kdDebug( 12006 ) << "Parse: " << s << endl; MetarParser parser(m_StationDb, KGlobal::locale()->measureSystem()); d->wi = parser.processData(d->wi.reportLocation, s); - d->age = TQDateTime::currentDateTime().addSecs(1800); + d->age = TQDateTime::tqcurrentDateTime().addSecs(1800); emit fileUpdate(d->wi.reportLocation); d->updated = true; } @@ -144,7 +144,7 @@ void WeatherLib::slotCopyDone(KIO::Job* job) // File error kdDebug( 12006 ) << "File empty error..." << endl; KPassivePopup::message( i18n("KWeather Error!"), - i18n("The temp file %1 was empty.").arg(d->target->name()), 0L,"error" ); + i18n("The temp file %1 was empty.").tqarg(d->target->name()), 0L,"error" ); d->updated = false; } } @@ -153,7 +153,7 @@ void WeatherLib::slotCopyDone(KIO::Job* job) // File error kdDebug( 12006 ) << "File read error..." << endl; KPassivePopup::message( i18n("KWeather Error!"), - i18n("Could not read the temp file %1.").arg(d->target->name()), 0L,"error" ); + i18n("Could not read the temp file %1.").tqarg(d->target->name()), 0L,"error" ); d->updated = false; } delete d->target; @@ -197,7 +197,7 @@ void WeatherLib::getData(Data *d, bool force /* try even if host was down last t u += d->wi.reportLocation.upper().stripWhiteSpace(); u += ".TXT"; - d->target = new KTempFile(TQString::null, "-weather"); + d->target = new KTempFile(TQString(), "-weather"); d->target->setAutoDelete(true); d->target->file(); @@ -322,7 +322,7 @@ void WeatherLib::update(const TQString &stationID) // Only grab new data if its more than 50 minutes old Data *d = findData(stationID); - TQDateTime timeout = TQDateTime::currentDateTime(); + TQDateTime timeout = TQDateTime::tqcurrentDateTime(); kdDebug (12006) << "Current Time: " << KGlobal::locale()->formatDateTime(timeout, false, false) << " Update at: " << KGlobal::locale()->formatDateTime(d->age, false, false) << endl; -- cgit v1.2.1