summaryrefslogtreecommitdiffstats
path: root/kweather
diff options
context:
space:
mode:
Diffstat (limited to 'kweather')
-rw-r--r--kweather/dockwidget.cpp114
-rw-r--r--kweather/dockwidget.h9
-rw-r--r--kweather/kcmweather.cpp20
-rw-r--r--kweather/kcmweather.h7
-rw-r--r--kweather/kcmweatherservice.cpp16
-rw-r--r--kweather/kcmweatherservice.h7
-rw-r--r--kweather/kweather.cpp22
-rw-r--r--kweather/kweather.h3
-rw-r--r--kweather/main.cpp2
-rw-r--r--kweather/metar_parser.cpp110
-rw-r--r--kweather/metar_parser.h2
-rw-r--r--kweather/prefdialogdata.ui48
-rw-r--r--kweather/reportview.cpp32
-rw-r--r--kweather/reportview.h1
-rw-r--r--kweather/serviceconfigdata.ui28
-rw-r--r--kweather/serviceconfigwidget.cpp10
-rw-r--r--kweather/serviceconfigwidget.h3
-rw-r--r--kweather/sidebarwidget.cpp4
-rw-r--r--kweather/sidebarwidget.h3
-rw-r--r--kweather/sidebarwidgetbase.ui14
-rw-r--r--kweather/stationdatabase.cpp8
-rw-r--r--kweather/sun.cpp8
-rw-r--r--kweather/sun.h2
-rw-r--r--kweather/weatherbar.cpp8
-rw-r--r--kweather/weatherbar.h7
-rw-r--r--kweather/weatherbutton.cpp12
-rw-r--r--kweather/weatherbutton.h5
-rw-r--r--kweather/weatherlib.cpp18
-rw-r--r--kweather/weatherlib.h5
-rw-r--r--kweather/weatherservice.cpp2
-rw-r--r--kweather/weatherservice.h3
31 files changed, 272 insertions, 261 deletions
diff --git a/kweather/dockwidget.cpp b/kweather/dockwidget.cpp
index b100ec9..6005315 100644
--- a/kweather/dockwidget.cpp
+++ b/kweather/dockwidget.cpp
@@ -30,8 +30,8 @@
#include <kglobalsettings.h>
#include <klocale.h>
-dockwidget::dockwidget(const TQString &location, TQWidget *parent,
- const char *name) : TQWidget(parent,name), m_locationCode( location ), m_orientation( Horizontal )
+dockwidget::dockwidget(const TQString &location, TQWidget *tqparent,
+ const char *name) : TQWidget(tqparent,name), m_locationCode( location ), m_orientation(Qt::Horizontal )
{
m_font = KGlobalSettings::generalFont();
setBackgroundOrigin( AncestorOrigin );
@@ -112,19 +112,19 @@ void dockwidget::showWeather()
"<th><nobr>" + i18n( "Rel. Humidity:" ) + "</nobr></th><td><nobr>%4</nobr></td></nobr></tr>"
"<tr><th><nobr>" + i18n( "Wind Speed:" ) + "</nobr></th><td><nobr>%5</nobr></td>")
- .arg(temp).arg(dewPoint).arg(pressure).arg(relHumidity).arg(wind);
+ .tqarg(temp).tqarg(dewPoint).tqarg(pressure).tqarg(relHumidity).tqarg(wind);
if ( !heatIndex.isEmpty() )
- tip += TQString("<th><nobr>" + i18n( "Heat Index:" ) + "</nobr></th><td><nobr>%1</nobr></td>").arg(heatIndex);
+ tip += TQString("<th><nobr>" + i18n( "Heat Index:" ) + "</nobr></th><td><nobr>%1</nobr></td>").tqarg(heatIndex);
else if ( !windChill.isEmpty() )
- tip += TQString("<th><nobr>" + i18n( "Wind Chill:" ) + "</nobr></th><td><nobr>%1</nobr></td>").arg(windChill);
+ tip += TQString("<th><nobr>" + i18n( "Wind Chill:" ) + "</nobr></th><td><nobr>%1</nobr></td>").tqarg(windChill);
else
tip += "<td>&nbsp;</td><td>&nbsp;</td>";
tip += "</tr>";
tip += TQString("<tr><th><nobr>" + i18n( "Sunrise:" ) + "</nobr></th><td><nobr>%1</nobr></td>" +
"<th><nobr>" + i18n( "Sunset:" ) + "</nobr></th><td><nobr>%2</nobr></td>")
- .arg(sunRiseTime).arg(sunSetTime);
+ .tqarg(sunRiseTime).tqarg(sunSetTime);
tip += "</tr></table>";
@@ -182,14 +182,14 @@ void dockwidget::initDock()
TQBoxLayout *mainLayout = new TQBoxLayout(this, TQBoxLayout::TopToBottom);
mainLayout->setSpacing(0);
mainLayout->setMargin(0);
- mainLayout->addWidget(m_button, 0, Qt::AlignCenter);
+ mainLayout->addWidget(m_button, 0, TQt::AlignCenter);
- TQBoxLayout *layout = new TQBoxLayout(mainLayout, TQBoxLayout::TopToBottom);
- layout->setSpacing(0);
- layout->setMargin(0);
- layout->addWidget(m_lblTemp);
- layout->addWidget(m_lblWind);
- layout->addWidget(m_lblPres);
+ TQBoxLayout *tqlayout = new TQBoxLayout(mainLayout, TQBoxLayout::TopToBottom);
+ tqlayout->setSpacing(0);
+ tqlayout->setMargin(0);
+ tqlayout->addWidget(m_lblTemp);
+ tqlayout->addWidget(m_lblWind);
+ tqlayout->addWidget(m_lblPres);
mainLayout->addSpacing(8);
@@ -204,27 +204,27 @@ void dockwidget::resizeView( const TQSize &size )
kdDebug(12004) << "Changing to size " << size << endl;
resize(size);
- if ( m_orientation == Horizontal ) // Kicker in horizontal mode
+ if ( m_orientation ==Qt::Horizontal ) // Kicker in horizontal mode
{
int h = size.height();
if ( m_mode == ShowAll )
{
- if ( h <= 128 ) // left to right layout
+ if ( h <= 128 ) // left to right tqlayout
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
- m_lblTemp->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
- m_lblWind->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
- m_lblPres->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight);
+ m_lblTemp->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
+ m_lblWind->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
+ m_lblPres->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
}
else // top to bottom
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom);
TQFontMetrics fm(m_font);
h = 128 - (3 * fm.height()); // 3 lines of text below the button
- m_lblTemp->setAlignment(Qt::AlignCenter);
- m_lblWind->setAlignment(Qt::AlignCenter);
- m_lblPres->setAlignment(Qt::AlignCenter);
+ m_lblTemp->tqsetAlignment(TQt::AlignCenter);
+ m_lblWind->tqsetAlignment(TQt::AlignCenter);
+ m_lblPres->tqsetAlignment(TQt::AlignCenter);
}
m_button->setFixedSize(h, h);
}
@@ -232,21 +232,21 @@ void dockwidget::resizeView( const TQSize &size )
{
if ( h <= 32 ) // left to right
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
- m_lblTemp->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight);
+ m_lblTemp->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
}
else // top to bottom
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom);
TQFontMetrics fm(m_font);
- h = QMIN(128, h) - fm.height();
- m_lblTemp->setAlignment(Qt::AlignCenter);
+ h = TQMIN(128, h) - fm.height();
+ m_lblTemp->tqsetAlignment(TQt::AlignCenter);
}
m_button->setFixedSize(h, h);
}
else
{
- h = QMIN(h, 128);
+ h = TQMIN(h, 128);
m_button->setFixedSize(h, h);
}
}
@@ -259,21 +259,21 @@ void dockwidget::resizeView( const TQSize &size )
{
if ( w <= 128 ) // top to bottom
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
- m_lblTemp->setAlignment(Qt::AlignCenter);
- m_lblWind->setAlignment(Qt::AlignCenter);
- m_lblPres->setAlignment(Qt::AlignCenter);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom);
+ m_lblTemp->tqsetAlignment(TQt::AlignCenter);
+ m_lblWind->tqsetAlignment(TQt::AlignCenter);
+ m_lblPres->tqsetAlignment(TQt::AlignCenter);
TQFontMetrics fm(m_font);
h = h - (3 * fm.height()); // 3 lines of text below the button
- h = QMIN(w, h);
+ h = TQMIN(w, h);
}
- else // left to right layout
+ else // left to right tqlayout
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
- m_lblTemp->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
- m_lblWind->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
- m_lblPres->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight);
+ m_lblTemp->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
+ m_lblWind->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
+ m_lblPres->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
}
m_button->setFixedSize(h, h);
}
@@ -281,15 +281,15 @@ void dockwidget::resizeView( const TQSize &size )
{
if ( w <= 128 ) // top to bottom
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::TopToBottom);
- m_lblTemp->setAlignment(Qt::AlignCenter);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::TopToBottom);
+ m_lblTemp->tqsetAlignment(TQt::AlignCenter);
h = w;
}
- else // left to right layout
+ else // left to right tqlayout
{
- static_cast<TQBoxLayout*>(layout())->setDirection(TQBoxLayout::LeftToRight);
- m_lblTemp->setAlignment(Qt::AlignAuto | Qt::AlignVCenter);
+ static_cast<TQBoxLayout*>(tqlayout())->setDirection(TQBoxLayout::LeftToRight);
+ m_lblTemp->tqsetAlignment(TQt::AlignAuto | TQt::AlignVCenter);
h = static_cast<int>(w * 0.33);
}
@@ -297,7 +297,7 @@ void dockwidget::resizeView( const TQSize &size )
}
else
{
- w = QMIN(w, 128);
+ w = TQMIN(w, 128);
m_button->setFixedSize(w, w);
}
}
@@ -310,13 +310,13 @@ int dockwidget::widthForHeight(int h)
if ( m_mode == ShowAll )
{
- if ( h <= 128 ) // left to right layout
+ if ( h <= 128 ) // left to right tqlayout
{
int pixelSize = h/3 - 3;
- pixelSize = QMIN(pixelSize, fi.pixelSize()); // don't make it too large
+ pixelSize = TQMIN(pixelSize, fi.pixelSize()); // don't make it too large
m_font.setPixelSize(pixelSize);
TQFontMetrics fm(m_font);
- w = h + QMAX(fm.width(m_lblWind->text()), fm.width(m_lblPres->text())) + 1;
+ w = h + TQMAX(fm.width(m_lblWind->text()), fm.width(m_lblPres->text())) + 1;
}
else // top to bottom
{
@@ -331,16 +331,16 @@ int dockwidget::widthForHeight(int h)
TQFontMetrics fm(m_font);
// size of icon
h = 128 - (3 * fm.height()); // 3 lines of text below the button
- w = QMAX(fm.width(m_lblWind->text()), fm.width(m_lblPres->text())) + 1;
- w = QMAX(h, w); // at least width of square icon
+ w = TQMAX(fm.width(m_lblWind->text()), fm.width(m_lblPres->text())) + 1;
+ w = TQMAX(h, w); // at least width of square icon
}
}
else if ( m_mode == ShowTempOnly )
{
- if ( h <= 32 ) // left to right layout
+ if ( h <= 32 ) // left to right tqlayout
{
int pixelSize = h - 3;
- pixelSize = QMIN(pixelSize, fi.pixelSize()); // don't make it too large
+ pixelSize = TQMIN(pixelSize, fi.pixelSize()); // don't make it too large
m_font.setPixelSize(pixelSize);
TQFontMetrics fm(m_font);
w = h + fm.width(m_lblTemp->text()) + 1;
@@ -357,14 +357,14 @@ int dockwidget::widthForHeight(int h)
}
TQFontMetrics fm(m_font);
// size of icon
- h = QMIN(128, h) - fm.height();
+ h = TQMIN(128, h) - fm.height();
w = fm.width(m_lblTemp->text()) + 1;
- w = QMAX(h, w); // at least width of square icon
+ w = TQMAX(h, w); // at least width of square icon
}
}
else
{
- w = QMIN(128, h); // don't make it too large
+ w = TQMIN(128, h); // don't make it too large
}
updateFont();
@@ -441,12 +441,12 @@ int dockwidget::heightForWidth( int w )
}
TQFontMetrics fm(m_font);
- h = QMAX(fm.height(), static_cast<int>(w * 0.33));
+ h = TQMAX(fm.height(), static_cast<int>(w * 0.33));
}
}
else
{
- h = QMIN(128, w); // don't make it too large
+ h = TQMIN(128, w); // don't make it too large
}
updateFont();
diff --git a/kweather/dockwidget.h b/kweather/dockwidget.h
index 4c8e478..72c1a43 100644
--- a/kweather/dockwidget.h
+++ b/kweather/dockwidget.h
@@ -28,19 +28,20 @@ class TQLabel;
class WeatherService_stub;
class WeatherButton;
-class dockwidget : public QWidget
+class dockwidget : public TQWidget
{
Q_OBJECT
+ TQ_OBJECT
public:
- dockwidget(const TQString &location, TQWidget *parent=0, const char *name=0);
+ dockwidget(const TQString &location, TQWidget *tqparent=0, const char *name=0);
~dockwidget();
enum {ShowIconOnly=1, ShowTempOnly=2, ShowAll=3 };
void setLocationCode(const TQString &locationCode);
void setViewMode(int);
- void setOrientation(Orientation o) { m_orientation = o; }
+ void setOrientation(Qt::Orientation o) { m_orientation = o; }
/** resize the view **/
void resizeView(const TQSize &size);
int widthForHeight(int h);
@@ -64,7 +65,7 @@ private:
TQLabel *m_lblTemp;
TQLabel *m_lblWind;
TQLabel *m_lblPres;
- Orientation m_orientation;
+ Qt::Orientation m_orientation;
WeatherService_stub *m_weatherService;
};
diff --git a/kweather/kcmweather.cpp b/kweather/kcmweather.cpp
index a4ed311..7388dc8 100644
--- a/kweather/kcmweather.cpp
+++ b/kweather/kcmweather.cpp
@@ -17,8 +17,8 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
As a special exception, permission is given to link this program
- with any edition of Qt, and distribute the resulting executable,
- without including the source code for Qt in the source distribution.
+ with any edition of TQt, and distribute the resulting executable,
+ without including the source code for TQt in the source distribution.
*/
#include <tqbuttongroup.h>
@@ -43,23 +43,23 @@
extern "C"
{
- KDE_EXPORT KCModule *create_weather( TQWidget *parent, const char * )
+ KDE_EXPORT KCModule *create_weather( TQWidget *tqparent, const char * )
{
- return new KCMWeather( parent, "kweather" );
+ return new KCMWeather( tqparent, "kweather" );
}
}
-KCMWeather::KCMWeather( TQWidget *parent, const char *name )
- : KCModule( parent, name )
+KCMWeather::KCMWeather( TQWidget *tqparent, const char *name )
+ : KCModule( tqparent, name )
{
mWeatherService = new WeatherService_stub( "KWeatherService",
"WeatherService" );
- TQVBoxLayout *layout = new TQVBoxLayout( this );
+ TQVBoxLayout *tqlayout = new TQVBoxLayout( this );
mWidget = new prefsDialogData( this );
mWidget->m_reportLocation->setFocus();
- layout->addWidget( mWidget );
- layout->addStretch();
+ tqlayout->addWidget( mWidget );
+ tqlayout->addStretch();
fillStationList();
load();
@@ -169,7 +169,7 @@ void KCMWeather::load()
mWidget->m_enableLog->setChecked( enabled );
enableLogWidgets( enabled );
- static TQColor black(Qt::black);
+ static TQColor black(TQt::black);
TQColor textColor = config.readColorEntry("textColor", &black);
mWidget->m_textColor->setColor(textColor);
diff --git a/kweather/kcmweather.h b/kweather/kcmweather.h
index 0c90ed3..8a836f1 100644
--- a/kweather/kcmweather.h
+++ b/kweather/kcmweather.h
@@ -16,8 +16,8 @@
along with this program; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
As a special exception, permission is given to link this program
- with any edition of Qt, and distribute the resulting executable,
- without including the source code for Qt in the source distribution.
+ with any edition of TQt, and distribute the resulting executable,
+ without including the source code for TQt in the source distribution.
*/
#ifndef KCMWEATHER_H
@@ -30,9 +30,10 @@ class prefsDialogData;
class KCMWeather : public KCModule
{
Q_OBJECT
+ TQ_OBJECT
public:
- KCMWeather( TQWidget *parent = 0, const char *name = 0 );
+ KCMWeather( TQWidget *tqparent = 0, const char *name = 0 );
~KCMWeather();
virtual void load();
diff --git a/kweather/kcmweatherservice.cpp b/kweather/kcmweatherservice.cpp
index 16bd80a..834d77a 100644
--- a/kweather/kcmweatherservice.cpp
+++ b/kweather/kcmweatherservice.cpp
@@ -17,8 +17,8 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
As a special exception, permission is given to link this program
- with any edition of Qt, and distribute the resulting executable,
- without including the source code for Qt in the source distribution.
+ with any edition of TQt, and distribute the resulting executable,
+ without including the source code for TQt in the source distribution.
*/
#include <tqlayout.h>
@@ -33,21 +33,21 @@
extern "C"
{
- KDE_EXPORT KCModule *create_weatherservice( TQWidget *parent, const char * ) {
- return new KCMWeatherService( parent, "kweather" );
+ KDE_EXPORT KCModule *create_weatherservice( TQWidget *tqparent, const char * ) {
+ return new KCMWeatherService( tqparent, "kweather" );
}
}
-KCMWeatherService::KCMWeatherService( TQWidget *parent, const char *name )
- : KCModule( parent, name )
+KCMWeatherService::KCMWeatherService( TQWidget *tqparent, const char *name )
+ : KCModule( tqparent, name )
{
- TQVBoxLayout *layout = new TQVBoxLayout( this );
+ TQVBoxLayout *tqlayout = new TQVBoxLayout( this );
mWidget = new ServiceConfigWidget( this );
// not needed, as a change immediately changes the service
//connect(mWidget, TQT_SIGNAL(changed(bool)), this, TQT_SIGNAL(changed(bool)));
- layout->addWidget( mWidget );
+ tqlayout->addWidget( mWidget );
KAboutData *about = new KAboutData( "kcmweatherservice",
I18N_NOOP( "KWeather Configure Dialog" ),
0, 0, KAboutData::License_GPL,
diff --git a/kweather/kcmweatherservice.h b/kweather/kcmweatherservice.h
index 9dfb0bd..bd5075e 100644
--- a/kweather/kcmweatherservice.h
+++ b/kweather/kcmweatherservice.h
@@ -17,8 +17,8 @@
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
As a special exception, permission is given to link this program
- with any edition of Qt, and distribute the resulting executable,
- without including the source code for Qt in the source distribution.
+ with any edition of TQt, and distribute the resulting executable,
+ without including the source code for TQt in the source distribution.
*/
#ifndef KCMWEATHERSERVICE_H
@@ -31,9 +31,10 @@ class ServiceConfigWidget;
class KCMWeatherService : public KCModule
{
Q_OBJECT
+ TQ_OBJECT
public:
- KCMWeatherService( TQWidget *parent = 0, const char *name = 0 );
+ KCMWeatherService( TQWidget *tqparent = 0, const char *name = 0 );
virtual void load();
virtual void save();
diff --git a/kweather/kweather.cpp b/kweather/kweather.cpp
index c6a7e9d..d65be55 100644
--- a/kweather/kweather.cpp
+++ b/kweather/kweather.cpp
@@ -40,20 +40,20 @@
extern "C"
{
- KDE_EXPORT KPanelApplet* init(TQWidget *parent, const TQString& configFile)
+ KDE_EXPORT KPanelApplet* init(TQWidget *tqparent, const TQString& configFile)
{
KGlobal::locale()->insertCatalogue("kweather");
kweather *theApplet = new kweather(configFile, KPanelApplet::Normal,
- 0, parent, "kweather");
+ 0, tqparent, "kweather");
return theApplet;
}
}
kweather::kweather(const TQString& configFile, Type t, int actions,
- TQWidget *parent, const char *name):
- KPanelApplet(configFile, t, actions, parent, name), weatherIface(),
+ TQWidget *tqparent, const char *name):
+ KPanelApplet(configFile, t, actions, tqparent, name), weatherIface(),
mFirstRun( false ), mReport( 0 ), mClient( 0 ),
- mContextMenu( 0 ), mWeatherService( 0 ), settingsDialog( 0 ), mTextColor(Qt::black)
+ mContextMenu( 0 ), mWeatherService( 0 ), settingsDialog( 0 ), mTextColor(TQt::black)
{
kdDebug(12004) << "Constructor " << endl;
setObjId("weatherIface");
@@ -86,7 +86,7 @@ kweather::~kweather()
void kweather::initContextMenu()
{
mContextMenu = new KPopupMenu(this);
- mContextMenu->insertTitle(i18n("KWeather - %1").arg( reportLocation ), -1, 0);
+ mContextMenu->insertTitle(i18n("KWeather - %1").tqarg( reportLocation ), -1, 0);
mContextMenu->insertItem(SmallIcon("viewmag"), i18n("Show &Report"),
this, TQT_SLOT(doReport()), 0, -1, 1);
mContextMenu->insertItem(SmallIcon("reload"), i18n("&Update Now"),
@@ -171,7 +171,7 @@ void kweather::preferences()
/** The help handler */
void kweather::help()
{
- kapp->invokeHelp(TQString::null, TQString::fromLatin1("kweather"));
+ kapp->invokeHelp(TQString(), TQString::tqfromLatin1("kweather"));
}
/** Display the current weather report. */
@@ -216,7 +216,7 @@ void kweather::loadPrefs(){
reportLocation = kcConfig->readEntry("report_location");
mViewMode = kcConfig->readNumEntry("smallview_mode", dockwidget::ShowAll);
- static TQColor black(Qt::black);
+ static TQColor black(TQt::black);
mTextColor = kcConfig->readColorEntry("textColor", &black);
}
@@ -299,7 +299,7 @@ void kweather::timeout()
int kweather::widthForHeight(int h) const
{
//kdDebug(12004) << "widthForHeight " << h << endl;
- dockWidget->setOrientation(Horizontal);
+ dockWidget->setOrientation(Qt::Horizontal);
int w = dockWidget->widthForHeight(h);
return w;
}
@@ -307,7 +307,7 @@ int kweather::widthForHeight(int h) const
int kweather::heightForWidth(int w) const
{
kdDebug(12004) << "heightForWidth " << w<< endl;
- dockWidget->setOrientation(Vertical);
+ dockWidget->setOrientation(Qt::Vertical);
int h = dockWidget->heightForWidth( w );
return h;
}
@@ -363,7 +363,7 @@ void kweather::slotPrefsAccepted()
void kweather::mousePressEvent(TQMouseEvent *e)
{
- if ( e->button() != RightButton )
+ if ( e->button() != Qt::RightButton )
{
KPanelApplet::mousePressEvent( e );
return;
diff --git a/kweather/kweather.h b/kweather/kweather.h
index 67516c4..70f0a44 100644
--- a/kweather/kweather.h
+++ b/kweather/kweather.h
@@ -33,9 +33,10 @@ class TQPalette;
class kweather : public KPanelApplet, public weatherIface
{
Q_OBJECT
+ TQ_OBJECT
public:
- kweather(const TQString& configFile, Type t = Normal, int actions = 0, TQWidget *parent = 0, const char *name = 0);
+ kweather(const TQString& configFile, Type t = Normal, int actions = 0, TQWidget *tqparent = 0, const char *name = 0);
~kweather();
void help();
void resizeEvent(TQResizeEvent*);
diff --git a/kweather/main.cpp b/kweather/main.cpp
index d6e8caa..e6ede73 100644
--- a/kweather/main.cpp
+++ b/kweather/main.cpp
@@ -29,7 +29,7 @@ int main (int argc, char *argv[])
// This app is started automatically, no need for session management
app.disableSessionManagement();
kdDebug() << "starting dcopservice " << endl;
- new WeatherService(&app, "WeatherService");
+ new WeatherService(TQT_TQOBJECT(&app), "WeatherService");
return app.exec();
}
diff --git a/kweather/metar_parser.cpp b/kweather/metar_parser.cpp
index 0339247..5789ff3 100644
--- a/kweather/metar_parser.cpp
+++ b/kweather/metar_parser.cpp
@@ -54,7 +54,7 @@ MetarParser::MetarParser(StationDatabase *stationDB,
void MetarParser::reset()
{
// Initialize the WeatherInfo structure
- weatherInfo.theWeather = TQString::null;
+ weatherInfo.theWeather = TQString();
weatherInfo.clouds = 0;
weatherInfo.windMPH = 0;
weatherInfo.tempC = 0;
@@ -64,15 +64,15 @@ void MetarParser::reset()
weatherInfo.qsCurrentList.clear();
weatherInfo.qsDate = m_date;
weatherInfo.qsTime = m_time;
- weatherInfo.qsPressure = TQString::null;
- weatherInfo.qsTemperature = TQString::null;
- weatherInfo.qsDewPoint = TQString::null;
- weatherInfo.qsRelHumidity = TQString::null;
- weatherInfo.qsVisibility = TQString::null;
- weatherInfo.qsWindSpeed = TQString::null;
- weatherInfo.qsWindChill = TQString::null;
- weatherInfo.qsHeatIndex = TQString::null;
- weatherInfo.qsWindDirection = TQString::null;
+ weatherInfo.qsPressure = TQString();
+ weatherInfo.qsTemperature = TQString();
+ weatherInfo.qsDewPoint = TQString();
+ weatherInfo.qsRelHumidity = TQString();
+ weatherInfo.qsVisibility = TQString();
+ weatherInfo.qsWindSpeed = TQString();
+ weatherInfo.qsWindChill = TQString();
+ weatherInfo.qsHeatIndex = TQString();
+ weatherInfo.qsWindDirection = TQString();
weatherInfo.stationNeedsMaintenance = false;
}
@@ -147,7 +147,7 @@ bool MetarParser::parseCover(const TQString &s)
{
if (CoverRegExp.search(s) > -1)
{
- kdDebug(12006) << "Cover: " << CoverRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Cover: " << TQString(CoverRegExp.tqcapturedTexts().join("-"))
<< endl;
TQString sCode = CoverRegExp.cap(1);
@@ -170,22 +170,22 @@ bool MetarParser::parseCover(const TQString &s)
if (sCode == "FEW")
{
- skycondition = i18n( "Few clouds at %1" ).arg(sClouds);
+ skycondition = i18n( "Few clouds at %1" ).tqarg(sClouds);
weatherInfo.clouds += 2;
}
else if (sCode == "SCT")
{
- skycondition = i18n( "Scattered clouds at %1" ).arg(sClouds);
+ skycondition = i18n( "Scattered clouds at %1" ).tqarg(sClouds);
weatherInfo.clouds += 4;
}
else if (sCode == "BKN")
{
- skycondition = i18n( "Broken clouds at %1" ).arg(sClouds);
+ skycondition = i18n( "Broken clouds at %1" ).tqarg(sClouds);
weatherInfo.clouds += 8;
}
else if (sCode == "OVC")
{
- skycondition = i18n( "Overcast clouds at %1" ).arg(sClouds);
+ skycondition = i18n( "Overcast clouds at %1" ).tqarg(sClouds);
weatherInfo.clouds += 64;
}
else if ((sCode == "CLR") || (sCode == "SKC") || (sCode == "CAVOK"))
@@ -211,7 +211,7 @@ bool MetarParser::parseCurrent(const TQString &s)
TQString sCode = CurrentRegExp.cap(2);
TQString intensity, descriptor, phenomena, currentWeather;
- kdDebug(12006) << "Current: " << CurrentRegExp.capturedTexts().join("-") << endl;
+ kdDebug(12006) << "Current: " << TQString(CurrentRegExp.tqcapturedTexts().join("-")) << endl;
// Decode the intensity
if (sIntensity == "+")
@@ -226,78 +226,78 @@ bool MetarParser::parseCurrent(const TQString &s)
}
// Decode the descriptor
- if (sCode.contains("MI"))
+ if (sCode.tqcontains("MI"))
descriptor = i18n("Shallow");
- else if (sCode.contains("PR"))
+ else if (sCode.tqcontains("PR"))
descriptor = i18n("Partial");
- else if (sCode.contains("BC"))
+ else if (sCode.tqcontains("BC"))
descriptor = i18n("Patches");
- else if (sCode.contains("DR"))
+ else if (sCode.tqcontains("DR"))
descriptor = i18n("Low Drifting");
- else if (sCode.contains("BL"))
+ else if (sCode.tqcontains("BL"))
descriptor = i18n("Blowing");
- else if (sCode.contains("SH"))
+ else if (sCode.tqcontains("SH"))
{
descriptor = i18n("Showers");
weatherInfo.theWeather = "shower";
}
- else if (sCode.contains("TS"))
+ else if (sCode.tqcontains("TS"))
{
descriptor = i18n("Thunder Storm");
weatherInfo.theWeather = "tstorm";
}
- else if (sCode.contains("FZ"))
+ else if (sCode.tqcontains("FZ"))
{
descriptor = i18n("Freezing");
}
// Decode weather phenomena
- if (sCode.contains("DZ"))
+ if (sCode.tqcontains("DZ"))
{
phenomena = i18n("Drizzle");
weatherInfo.theWeather = "light_rain";
}
- else if (sCode.contains("RA"))
+ else if (sCode.tqcontains("RA"))
{
phenomena = i18n("Rain");
weatherInfo.theWeather = "shower";
}
- else if (sCode.contains("SN"))
+ else if (sCode.tqcontains("SN"))
{
phenomena = i18n("Snow");
weatherInfo.theWeather = "snow";
}
- else if (sCode.contains("SG"))
+ else if (sCode.tqcontains("SG"))
{
phenomena = i18n("Snow Grains");
weatherInfo.theWeather = "snow4";
}
- else if (sCode.contains("IC"))
+ else if (sCode.tqcontains("IC"))
{
phenomena = i18n("Ice Crystals");
weatherInfo.theWeather = "hail";
}
- else if (sCode.contains("PE"))
+ else if (sCode.tqcontains("PE"))
{
phenomena = i18n("Ice Pellets");
weatherInfo.theWeather = "hail";
}
- else if (s.contains("GR"))
+ else if (s.tqcontains("GR"))
{
phenomena = i18n("Hail");
weatherInfo.theWeather = "hail";
}
- else if (sCode.contains("GS"))
+ else if (sCode.tqcontains("GS"))
{
phenomena = i18n("Small Hail Pellets");
weatherInfo.theWeather = "hail";
}
- else if (s.contains("UP"))
+ else if (s.tqcontains("UP"))
{
phenomena = i18n("Unknown Precipitation");
weatherInfo.theWeather = iconName("shower1");
}
- else if (sCode.contains("BR"))
+ else if (sCode.tqcontains("BR"))
{
phenomena = i18n("Mist");
// Mist has lower priority than say rain or snow
@@ -306,7 +306,7 @@ bool MetarParser::parseCurrent(const TQString &s)
weatherInfo.theWeather = "mist";
}
}
- else if (sCode.contains("FG"))
+ else if (sCode.tqcontains("FG"))
{
phenomena = i18n("Fog");
// Fog has lower priority than say rain or snow
@@ -315,35 +315,35 @@ bool MetarParser::parseCurrent(const TQString &s)
weatherInfo.theWeather = "fog";
}
}
- else if (sCode.contains("FU"))
+ else if (sCode.tqcontains("FU"))
phenomena = i18n("Smoke");
- else if (sCode.contains("VA"))
+ else if (sCode.tqcontains("VA"))
phenomena = i18n("Volcanic Ash");
- else if (sCode.contains("DU"))
+ else if (sCode.tqcontains("DU"))
phenomena = i18n("Widespread Dust");
- else if (sCode.contains("SA"))
+ else if (sCode.tqcontains("SA"))
phenomena = i18n("Sand");
- else if (sCode.contains("HZ"))
+ else if (sCode.tqcontains("HZ"))
phenomena = i18n("Haze");
- else if (sCode.contains("PY"))
+ else if (sCode.tqcontains("PY"))
phenomena = i18n("Spray");
- else if (sCode.contains("PO"))
+ else if (sCode.tqcontains("PO"))
phenomena = i18n("Dust/Sand Swirls");
- else if (sCode.contains("SQ"))
+ else if (sCode.tqcontains("SQ"))
phenomena = i18n("Sudden Winds");
- else if (sCode.contains("FC"))
+ else if (sCode.tqcontains("FC"))
{
if (sIntensity == "+")
currentWeather = i18n("Tornado");
else
phenomena = i18n("Funnel Cloud");
}
- else if (sCode.contains("SS"))
+ else if (sCode.tqcontains("SS"))
phenomena = i18n("Sand Storm");
- else if (sCode.contains("DS"))
+ else if (sCode.tqcontains("DS"))
phenomena = i18n("Dust Storm");
- if (currentWeather.isEmpty()) currentWeather = i18n("%1 is the intensity, %2 is the descriptor and %3 is the phenomena", "%1 %2 %3").arg(intensity).arg(descriptor).arg(phenomena);
+ if (currentWeather.isEmpty()) currentWeather = i18n("%1 is the intensity, %2 is the descriptor and %3 is the phenomena", "%1 %2 %3").tqarg(intensity).tqarg(descriptor).tqarg(phenomena);
if (!currentWeather.isEmpty())
weatherInfo.qsCurrentList << currentWeather;
@@ -358,7 +358,7 @@ bool MetarParser::parseTemperature(const TQString &s)
{
if (TempRegExp.search(s) > -1)
{
- kdDebug(12006) << "Temp: " << TempRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Temp: " << TQString(TempRegExp.tqcapturedTexts().join("-"))
<< endl;
float fTemp = TempRegExp.cap(2).toFloat();
@@ -379,7 +379,7 @@ bool MetarParser::parseTemperatureTenths(const TQString &s)
{
if (TempTenRegExp.search(s) > -1)
{
- kdDebug(12006) << "Temp Tenths: " << TempTenRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Temp Tenths: " << TQString(TempTenRegExp.tqcapturedTexts().join("-"))
<< endl;
float temperature = TempTenRegExp.cap( 1 ).toFloat() / 10;
@@ -473,7 +473,7 @@ bool MetarParser::parseDate(const TQString &s)
{
if (DateRegExp.search(s) > -1)
{
- kdDebug(12006) << "Date: " << DateRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Date: " << TQString(DateRegExp.tqcapturedTexts().join("-"))
<< endl;
TQString dateString = DateRegExp.cap(1);
TQString day, month, year;
@@ -496,7 +496,7 @@ bool MetarParser::parseTime(const TQString &s)
{
if (TimeRegExp.search(s) > -1)
{
- kdDebug(12006) << "Time: " << TimeRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Time: " << TQString(TimeRegExp.tqcapturedTexts().join("-"))
<< endl;
TQString hour, minute, dateString;
@@ -521,7 +521,7 @@ bool MetarParser::parseVisibility(TQStringList::ConstIterator it)
{
fVisibility = VisRegExp.cap(1).toFloat();
- kdDebug(12006) << "Visibility: " << VisRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Visibility: " << TQString(VisRegExp.tqcapturedTexts().join("-"))
<< endl;
}
@@ -564,7 +564,7 @@ bool MetarParser::parsePressure( const TQString &s)
TQString type = PressRegExp.cap(1);
float fPressure = PressRegExp.cap(2).toFloat();
- kdDebug(12006) << "Pressure: " << PressRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Pressure: " << TQString(PressRegExp.tqcapturedTexts().join("-"))
<< endl;
if (m_units == KLocale::Metric)
@@ -643,7 +643,7 @@ bool MetarParser::parseWindSpeed(const TQString &s)
float gustSpeed = WindRegExp.cap(3).toFloat();
TQString sWindUnit = WindRegExp.cap(4);
- kdDebug(12006) << "Wind: " << WindRegExp.capturedTexts().join("-")
+ kdDebug(12006) << "Wind: " << WindRegExp.tqcapturedTexts().join("-")
<< endl;
if (m_units == KLocale::Metric)
@@ -854,7 +854,7 @@ bool MetarParser::isNight(const TQString &stationID) const
// Midnight Sun & Polar Night - In summer, the Sun is always
// over the horizon line ... so use latitude & today date to
// set isNight() value.
- return ((m_date.daysInYear() >= 80 || m_date.daysInYear() <= 264) && latitude.contains("S"));
+ return ((m_date.daysInYear() >= 80 || m_date.daysInYear() <= 264) && latitude.tqcontains("S"));
}
}
}
diff --git a/kweather/metar_parser.h b/kweather/metar_parser.h
index daeddad..7d94149 100644
--- a/kweather/metar_parser.h
+++ b/kweather/metar_parser.h
@@ -60,7 +60,7 @@ class MetarParser
public:
MetarParser(StationDatabase *stationDB,
KLocale::MeasureSystem units = KLocale::Imperial,
- TQDate date = TQDate::currentDate(),
+ TQDate date = TQDate::tqcurrentDate(),
TQTime time = TQTime::currentTime(),
unsigned int localUTCOffset = KRFCDate::localUTCOffset());
diff --git a/kweather/prefdialogdata.ui b/kweather/prefdialogdata.ui
index e3d0f2e..907629e 100644
--- a/kweather/prefdialogdata.ui
+++ b/kweather/prefdialogdata.ui
@@ -1,7 +1,7 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>prefsDialogData</class>
<author>ian reinhart geiser &lt;geiseri@kde.org&gt;</author>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>prefsDialogData</cstring>
</property>
@@ -21,7 +21,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -37,7 +37,7 @@
<property name="margin">
<number>0</number>
</property>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>GroupBox2</cstring>
</property>
@@ -62,7 +62,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>TextLabel1_4_2_2</cstring>
</property>
@@ -85,7 +85,7 @@
<verstretch>0</verstretch>
</sizepolicy>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>0</width>
<height>0</height>
@@ -102,7 +102,7 @@
<property name="sizeType">
<enum>MinimumExpanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>40</width>
<height>20</height>
@@ -111,7 +111,7 @@
</spacer>
</hbox>
</widget>
- <widget class="QButtonGroup">
+ <widget class="TQButtonGroup">
<property name="name">
<cstring>m_viewMode</cstring>
</property>
@@ -129,7 +129,7 @@
<property name="title">
<string>Panel Display Options</string>
</property>
- <property name="alignment">
+ <property name="tqalignment">
<set>AlignVCenter|AlignLeft</set>
</property>
<property name="exclusive">
@@ -139,7 +139,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>m_smallView</cstring>
</property>
@@ -161,10 +161,10 @@
<string>&lt;qt&gt;Click here to show only the weather icon.&lt;/qt&gt;</string>
</property>
<property name="whatsThis" stdset="0">
- <string>This feature will allow you to make KWeather take up only one slot on the kicker. Normally this application will take up two slots. The small view will only show the weather icon, while the normal view will display both the icon and the current weather statistics. For the small view the weather statistics will be put on the buttons tool tip.</string>
+ <string>This feature will allow you to make KWeather take up only one slot on the kicker. Normally this application will take up two Q_SLOTS. The small view will only show the weather icon, while the normal view will display both the icon and the current weather statistics. For the small view the weather statistics will be put on the buttons tool tip.</string>
</property>
</widget>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>CheckBox9</cstring>
</property>
@@ -175,7 +175,7 @@
<number>2</number>
</property>
</widget>
- <widget class="QRadioButton">
+ <widget class="TQRadioButton">
<property name="name">
<cstring>CheckBox10</cstring>
</property>
@@ -191,7 +191,7 @@
</widget>
</vbox>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>GroupBox1</cstring>
</property>
@@ -210,7 +210,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QCheckBox" row="0" column="0" rowspan="1" colspan="2">
+ <widget class="TQCheckBox" row="0" column="0" rowspan="1" colspan="2">
<property name="name">
<cstring>m_enableLog</cstring>
</property>
@@ -228,14 +228,14 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>294</width>
<height>16</height>
</size>
</property>
</spacer>
- <widget class="QLabel" row="1" column="0">
+ <widget class="TQLabel" row="1" column="0">
<property name="name">
<cstring>m_labelLogFile</cstring>
</property>
@@ -256,7 +256,7 @@
<property name="enabled">
<bool>false</bool>
</property>
- <property name="minimumSize">
+ <property name="tqminimumSize">
<size>
<width>252</width>
<height>0</height>
@@ -271,7 +271,7 @@
</widget>
</grid>
</widget>
- <widget class="QGroupBox">
+ <widget class="TQGroupBox">
<property name="name">
<cstring>groupBox3</cstring>
</property>
@@ -282,15 +282,15 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget">
+ <widget class="TQLayoutWidget">
<property name="name">
- <cstring>layout1</cstring>
+ <cstring>tqlayout1</cstring>
</property>
<hbox>
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLabel">
+ <widget class="TQLabel">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -318,7 +318,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>170</width>
<height>20</height>
@@ -348,8 +348,8 @@
<includes>
<include location="local" impldecl="in implementation">kdialog.h</include>
</includes>
-<layoutdefaults spacing="3" margin="6"/>
-<layoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/>
+<tqlayoutdefaults spacing="3" margin="6"/>
+<tqlayoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/>
<includehints>
<includehint>kcombobox.h</includehint>
<includehint>kurlrequester.h</includehint>
diff --git a/kweather/reportview.cpp b/kweather/reportview.cpp
index 5cae65e..bba90cf 100644
--- a/kweather/reportview.cpp
+++ b/kweather/reportview.cpp
@@ -31,7 +31,7 @@
#include "weatherservice_stub.h"
reportView::reportView(const TQString &reportLocation)
- : KDialogBase( (TQWidget *)0, "report", false, TQString::null, Close ),
+ : KDialogBase( (TQWidget *)0, "report", false, TQString(), Close ),
m_locationCode(reportLocation)
{
TQVBox *vbox = makeVBoxMainWidget();
@@ -55,7 +55,7 @@ reportView::reportView(const TQString &reportLocation)
reportView::~reportView(){
delete m_weatherService;
// we do not have to delete m_reportView because this class is
- // the parent of the TQVBox, and that is the parent of the KHTMLPart.
+ // the tqparent of the TQVBox, and that is the tqparent of the KHTMLPart.
KConfig config( "weather_panelappletrc" );
config.setGroup( "General Options" );
@@ -72,7 +72,7 @@ void reportView::render(){
TQString textColor = KGlobalSettings::textColor().name();
TQString baseColor = KGlobalSettings::baseColor().name();
- TQColorGroup cg = palette().active();
+ TQColorGroup cg = tqpalette().active();
TQString bgColor = cg.background().name();
TQString hlColor = cg.highlight().name();
TQString hlTextColor = cg.highlightedText().name();
@@ -93,7 +93,7 @@ void reportView::render(){
TQStringList cover = m_weatherService->cover(m_locationCode );
TQStringList weather = m_weatherService->weather(m_locationCode );
- setCaption(i18n("Weather Report - %1").arg( locationName ) );
+ setCaption(i18n("Weather Report - %1").tqarg( locationName ) );
TQString weatherText = "<ul>\n";
@@ -114,24 +114,24 @@ void reportView::render(){
TQString contents =
"<html><head><style type=\"text/css\">" +
TQString("body { font-family: \"%1\"; font-size: %2pt; color: %3; background-color: %4; }\n")
- .arg(fntFamily).arg(fntSize).arg(textColor).arg(baseColor) +
+ .tqarg(fntFamily).tqarg(fntSize).tqarg(textColor).tqarg(baseColor) +
TQString("div.headerTitle { background-color: %1; color: %2; padding: 4px; font-size: 120%; border: solid %3 1px; }\n")
- .arg(hlColor).arg(hlTextColor).arg(textColor) +
+ .tqarg(hlColor).tqarg(hlTextColor).tqarg(textColor) +
TQString("div.headerMsg { background-color: %1; color: %2; border-bottom: solid %3 1px; "
"border-left: solid %4 1px; border-right: solid %5 1px; margin-bottom: 1em; padding: 2px; }\n")
- .arg(bgColor).arg(textColor).arg(textColor).arg(textColor).arg(textColor) +
- TQString("</style><title></title></head><body dir=\"%1\">").arg( TQApplication::reverseLayout()?"rtl":"ltr") +
- "<div class=\"headerTitle\"><b>" + i18n( "Weather Report - %1 - %2" ).arg( locationName ).arg( countryName ) +
+ .tqarg(bgColor).tqarg(textColor).tqarg(textColor).tqarg(textColor).tqarg(textColor) +
+ TQString("</style><title></title></head><body dir=\"%1\">").tqarg( TQApplication::reverseLayout()?"rtl":"ltr") +
+ "<div class=\"headerTitle\"><b>" + i18n( "Weather Report - %1 - %2" ).tqarg( locationName ).tqarg( countryName ) +
"</b></div>\n";
if ( ! date.isEmpty() )
- contents += "<div class=\"headerMsg\"><b>" + i18n( "Latest data from %1" ).arg(date) + "</b></div>\n";
+ contents += "<div class=\"headerMsg\"><b>" + i18n( "Latest data from %1" ).tqarg(date) + "</b></div>\n";
contents += TQString(
"<table><tr><td width=\"60\" style=\"text-align: center; border: dotted %1 1px;\">"
"<img width=\"64\" height=\"64\" src=\"%2\" /></td>"
"<td style=\"vertical-align: top\">%3</td></tr>")
- .arg(bgColor).arg(KURL(icon).url()).arg(weatherText) +
+ .tqarg(bgColor).tqarg(KURL(icon).url()).tqarg(weatherText) +
"</table><table>" +
TQString("<tr><th style=\"text-align: right\">" + i18n( "Temperature:" )
+ "</th><td>%1</td>"
@@ -145,15 +145,15 @@ void reportView::render(){
+ "</th><td>%4</td></tr>"
"<tr><th style=\"text-align: right\">" + i18n( "Wind Speed:" )
+ "</th><td>%5</td>")
- .arg(temp).arg(dewPoint).arg(pressure).arg(relHumidity)
- .arg(wind) + "<td width=\"50\">&nbsp;</td>";
+ .tqarg(temp).tqarg(dewPoint).tqarg(pressure).tqarg(relHumidity)
+ .tqarg(wind) + "<td width=\"50\">&nbsp;</td>";
if (!heatIndex.isEmpty())
contents += TQString("<th style=\"text-align: right\">"
- + i18n( "Heat Index:" ) + "</th><td>%1</td>").arg(heatIndex);
+ + i18n( "Heat Index:" ) + "</th><td>%1</td>").tqarg(heatIndex);
else if (!windChill.isEmpty())
contents += TQString("<th style=\"text-align: right\">"
- + i18n( "Wind Chill:" ) + "</th><td>%1</td>").arg(windChill);
+ + i18n( "Wind Chill:" ) + "</th><td>%1</td>").tqarg(windChill);
else
contents += "<td>&nbsp;</td><td>&nbsp;</td>";
contents += "</tr>";
@@ -162,7 +162,7 @@ void reportView::render(){
+ i18n( "Sunrise:" ) + "</th><td>%1</td>" +
"<td width=\"50\">&nbsp;</td><th style=\"text-align: right\">"
+ i18n( "Sunset:" ) + "</th><td>%2</td>")
- .arg(sunRiseTime).arg(sunSetTime);
+ .tqarg(sunRiseTime).tqarg(sunSetTime);
contents += "</tr></table></body></html>";
diff --git a/kweather/reportview.h b/kweather/reportview.h
index 5cbc082..31577df 100644
--- a/kweather/reportview.h
+++ b/kweather/reportview.h
@@ -31,6 +31,7 @@ class WeatherService_stub;
class reportView : public KDialogBase {
Q_OBJECT
+ TQ_OBJECT
public:
reportView(const TQString &reportLocation);
diff --git a/kweather/serviceconfigdata.ui b/kweather/serviceconfigdata.ui
index 5ebdcde..248c04b 100644
--- a/kweather/serviceconfigdata.ui
+++ b/kweather/serviceconfigdata.ui
@@ -1,7 +1,7 @@
<!DOCTYPE UI><UI version="3.3" stdsetdef="1">
<class>wsPrefs</class>
<author>Ian Reinhart Geiser &lt;geiseri@kde.org&gt;</author>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>wsPrefs</cstring>
</property>
@@ -28,7 +28,7 @@
<string>A&amp;dd</string>
</property>
</widget>
- <widget class="QLabel" row="0" column="2">
+ <widget class="TQLabel" row="0" column="2">
<property name="name">
<cstring>textLabel2</cstring>
</property>
@@ -39,7 +39,7 @@
<cstring>mSelectedStations</cstring>
</property>
</widget>
- <widget class="QLabel" row="0" column="0">
+ <widget class="TQLabel" row="0" column="0">
<property name="name">
<cstring>textLabel1</cstring>
</property>
@@ -60,7 +60,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>86</height>
@@ -121,7 +121,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>85</height>
@@ -167,9 +167,9 @@
<bool>false</bool>
</property>
</widget>
- <widget class="QLayoutWidget" row="5" column="0" rowspan="1" colspan="3">
+ <widget class="TQLayoutWidget" row="5" column="0" rowspan="1" colspan="3">
<property name="name">
- <cstring>layout1</cstring>
+ <cstring>tqlayout1</cstring>
</property>
<hbox>
<property name="name">
@@ -224,9 +224,9 @@
</connection>
<connection>
<sender>mSelectedStations</sender>
- <signal>selectionChanged(QListViewItem*)</signal>
+ <signal>selectionChanged(TQListViewItem*)</signal>
<receiver>wsPrefs</receiver>
- <slot>selectionChanged(QListViewItem*)</slot>
+ <slot>selectionChanged(TQListViewItem*)</slot>
</connection>
</connections>
<tabstops>
@@ -242,15 +242,15 @@
<include location="global" impldecl="in implementation">kdialog.h</include>
<include location="global" impldecl="in implementation">knuminput.h</include>
</includes>
-<slots>
+<Q_SLOTS>
<slot>exitWeatherService()</slot>
<slot>removeStation()</slot>
<slot>updateStations()</slot>
<slot>addStation()</slot>
- <slot>selectionChanged( QListViewItem* )</slot>
-</slots>
-<layoutdefaults spacing="3" margin="6"/>
-<layoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/>
+ <slot>selectionChanged( TQListViewItem* )</slot>
+</Q_SLOTS>
+<tqlayoutdefaults spacing="3" margin="6"/>
+<tqlayoutfunctions spacing="KDialog::spacingHint" margin="KDialog::marginHint"/>
<includehints>
<includehint>klistview.h</includehint>
<includehint>klistview.h</includehint>
diff --git a/kweather/serviceconfigwidget.cpp b/kweather/serviceconfigwidget.cpp
index 27a1013..8604f27 100644
--- a/kweather/serviceconfigwidget.cpp
+++ b/kweather/serviceconfigwidget.cpp
@@ -34,7 +34,7 @@
#include "serviceconfigwidget.h"
#include "weatherservice_stub.h"
-class StationItem : public QListViewItem
+class StationItem : public TQListViewItem
{
public:
StationItem( TQListView *view, const TQString &name, const TQString &uid )
@@ -55,8 +55,8 @@ class StationItem : public QListViewItem
static void parseStationEntry( const TQString &line, TQString &name, TQString &uid );
-ServiceConfigWidget::ServiceConfigWidget( TQWidget *parent, const char *name )
- : wsPrefs( parent, name ), mService(0)
+ServiceConfigWidget::ServiceConfigWidget( TQWidget *tqparent, const char *name )
+ : wsPrefs( tqparent, name ), mService(0)
{
mService = new WeatherService_stub( "KWeatherService", "WeatherService" );
connect( mAllStations, TQT_SIGNAL( doubleClicked ( TQListViewItem *, const TQPoint &, int ) ), TQT_SLOT( addStation() ) );
@@ -194,7 +194,7 @@ void ServiceConfigWidget::loadLocations()
parseStationEntry( entryIt.data(), station, uid );
new StationItem( stateItem, station, uid );
mStationMap.insert( uid, TQString( "%1, %2" )
- .arg( station ).arg( *stateIt ) );
+ .tqarg( station ).tqarg( *stateIt ) );
}
}
}
@@ -224,7 +224,7 @@ void parseStationEntry( const TQString &line, TQString &name, TQString &uid )
for ( uint i = 0; i < list.count(); ++i ) {
if ( inName ) {
if ( list[ i ].endsWith( "\\" ) ) {
- name.append( list[ i ].replace( "\\", " " ) );
+ name.append( list[ i ].tqreplace( "\\", " " ) );
} else {
name.append( list[ i ] );
inName = false;
diff --git a/kweather/serviceconfigwidget.h b/kweather/serviceconfigwidget.h
index 37ee1d5..3f65194 100644
--- a/kweather/serviceconfigwidget.h
+++ b/kweather/serviceconfigwidget.h
@@ -28,9 +28,10 @@ class WeatherService_stub;
class ServiceConfigWidget : public wsPrefs
{
Q_OBJECT
+ TQ_OBJECT
public:
- ServiceConfigWidget( TQWidget *parent, const char *name = 0 );
+ ServiceConfigWidget( TQWidget *tqparent, const char *name = 0 );
virtual ~ServiceConfigWidget();
signals:
diff --git a/kweather/sidebarwidget.cpp b/kweather/sidebarwidget.cpp
index 0a7c080..0ef9e30 100644
--- a/kweather/sidebarwidget.cpp
+++ b/kweather/sidebarwidget.cpp
@@ -22,8 +22,8 @@
#include "sidebarwidget.h"
#include <tqscrollview.h>
- sidebarwidget::sidebarwidget(TQWidget* parent, const char* name) :
- sidebarwidgetbase(parent,name)
+ sidebarwidget::sidebarwidget(TQWidget* tqparent, const char* name) :
+ sidebarwidgetbase(tqparent,name)
{
view = new TQVBox(reportGrid->viewport());
reportGrid->addChild(view);
diff --git a/kweather/sidebarwidget.h b/kweather/sidebarwidget.h
index 7bfb317..c917452 100644
--- a/kweather/sidebarwidget.h
+++ b/kweather/sidebarwidget.h
@@ -29,8 +29,9 @@
class sidebarwidget : public sidebarwidgetbase
{
Q_OBJECT
+ TQ_OBJECT
public:
- sidebarwidget(TQWidget* parent, const char* name = 0);
+ sidebarwidget(TQWidget* tqparent, const char* name = 0);
virtual ~sidebarwidget();
void addWidget(TQWidget *w, const TQString &s);
TQWidget *viewport();
diff --git a/kweather/sidebarwidgetbase.ui b/kweather/sidebarwidgetbase.ui
index fe84dce..31e139b 100644
--- a/kweather/sidebarwidgetbase.ui
+++ b/kweather/sidebarwidgetbase.ui
@@ -1,7 +1,7 @@
<!DOCTYPE UI><UI version="3.1" stdsetdef="1">
<class>sidebarwidgetbase</class>
<author>ian reinhart geiser &lt;geiseri@kde.org&gt;</author>
-<widget class="QWidget">
+<widget class="TQWidget">
<property name="name">
<cstring>Form1</cstring>
</property>
@@ -17,7 +17,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QGroupBox" row="1" column="0">
+ <widget class="TQGroupBox" row="1" column="0">
<property name="name">
<cstring>GroupBox2</cstring>
</property>
@@ -28,7 +28,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QLayoutWidget" row="0" column="0">
+ <widget class="TQLayoutWidget" row="0" column="0">
<property name="name">
<cstring>Layout1</cstring>
</property>
@@ -61,7 +61,7 @@
<property name="sizeType">
<enum>Expanding</enum>
</property>
- <property name="sizeHint">
+ <property name="tqsizeHint">
<size>
<width>20</width>
<height>20</height>
@@ -70,7 +70,7 @@
</spacer>
</grid>
</widget>
- <widget class="QGroupBox" row="0" column="0">
+ <widget class="TQGroupBox" row="0" column="0">
<property name="name">
<cstring>reportGroup</cstring>
</property>
@@ -81,7 +81,7 @@
<property name="name">
<cstring>unnamed</cstring>
</property>
- <widget class="QScrollView" row="0" column="0">
+ <widget class="TQScrollView" row="0" column="0">
<property name="name">
<cstring>reportGrid</cstring>
</property>
@@ -108,5 +108,5 @@
<pixmap>image0</pixmap>
</customwidget>
</customwidgets>
-<layoutdefaults spacing="5" margin="5"/>
+<tqlayoutdefaults spacing="5" margin="5"/>
</UI>
diff --git a/kweather/stationdatabase.cpp b/kweather/stationdatabase.cpp
index 0e2caac..a30a1f2 100644
--- a/kweather/stationdatabase.cpp
+++ b/kweather/stationdatabase.cpp
@@ -76,7 +76,7 @@ TQString StationDatabase::stationNameFromID( const TQString & stationID )
{
TQString result;
- if ( theDB.find( stationID ) == theDB.end() )
+ if ( theDB.tqfind( stationID ) == theDB.end() )
{
if ( loadStation( stationID ) )
result = theDB[ stationID ].cityName;
@@ -98,7 +98,7 @@ TQString StationDatabase::stationLongitudeFromID( const TQString & stationID )
{
TQString result;
- if ( theDB.find( stationID ) == theDB.end() )
+ if ( theDB.tqfind( stationID ) == theDB.end() )
{
if ( loadStation( stationID ) )
result = theDB[ stationID ].longitude;
@@ -120,7 +120,7 @@ TQString StationDatabase::stationLatitudeFromID( const TQString & stationID )
{
TQString result;
- if ( theDB.find( stationID ) == theDB.end() )
+ if ( theDB.tqfind( stationID ) == theDB.end() )
{
if ( loadStation( stationID ) )
result = theDB[ stationID ].latitude;
@@ -142,7 +142,7 @@ TQString StationDatabase::stationCountryFromID( const TQString &stationID )
{
TQString result;
- if ( theDB.find( stationID ) == theDB.end() )
+ if ( theDB.tqfind( stationID ) == theDB.end() )
{
if ( loadStation( stationID ) )
result = theDB[ stationID ].country;
diff --git a/kweather/sun.cpp b/kweather/sun.cpp
index 8cabdb9..50b89f0 100644
--- a/kweather/sun.cpp
+++ b/kweather/sun.cpp
@@ -176,7 +176,7 @@ static double latitudeToDouble( const TQString &latitude )
result = dd + (mm / 60);
- if (latitude.contains("S"))
+ if (latitude.tqcontains("S"))
result *= -1;
return result;
@@ -192,7 +192,7 @@ static double longitudeToDouble( const TQString &longitude )
result = ddd + (mm / 60);
- if (longitude.contains("W"))
+ if (longitude.tqcontains("W"))
result *= -1;
return result;
@@ -282,7 +282,7 @@ static int __sunriset__( int year, int month, int day, double lon, double lat,
double sr; /* Solar distance, astronomical units */
double sRA; /* Sun's Right Ascension */
double sdec; /* Sun's declination */
- double sradius; /* Sun's apparent radius */
+ double sradius; /* Sun's aptqparent radius */
double t; /* Diurnal arc */
double tsouth; /* Time when Sun is at south */
double sidtime; /* Local sidereal time */
@@ -303,7 +303,7 @@ static int __sunriset__( int year, int month, int day, double lon, double lat,
/* Compute time when Sun is at south - in hours UT */
tsouth = 12.0 - rev180(sidtime - sRA) / 15.0;
- /* Compute the Sun's apparent radius, degrees */
+ /* Compute the Sun's aptqparent radius, degrees */
sradius = 0.2666 / sr;
/* Do correction to upper limb, if necessary */
diff --git a/kweather/sun.h b/kweather/sun.h
index fd407d7..f56b513 100644
--- a/kweather/sun.h
+++ b/kweather/sun.h
@@ -37,7 +37,7 @@ class Sun
*/
Sun( const TQString &latitude,
const TQString &longitude,
- TQDate date = TQDate::currentDate(),
+ TQDate date = TQDate::tqcurrentDate(),
const int localUTCOffset = KRFCDate::localUTCOffset() );
TQTime computeRiseTime();
diff --git a/kweather/weatherbar.cpp b/kweather/weatherbar.cpp
index c77333d..eb01876 100644
--- a/kweather/weatherbar.cpp
+++ b/kweather/weatherbar.cpp
@@ -36,11 +36,11 @@
#include <dcopref.h>
-KonqSidebarWeather::KonqSidebarWeather(KInstance* inst, TQObject* parent,
+KonqSidebarWeather::KonqSidebarWeather(KInstance* inst, TQObject* tqparent,
TQWidget* widgetParent,
TQString& desktopName, const char* name)
- : KonqSidebarPlugin(inst, parent, widgetParent, desktopName, name),
+ : KonqSidebarPlugin(inst, tqparent, widgetParent, desktopName, name),
DCOPObject(name)
{
@@ -100,7 +100,7 @@ TQWidget* KonqSidebarWeather::getWidget()
void KonqSidebarWeather::refresh(TQString stationID)
{
kdDebug() << "refresh " << stationID << endl;
- if(m_widgets.find(stationID))
+ if(m_widgets.tqfind(stationID))
{
DCOPRef dcopCall( "KWeatherService", "WeatherService" );
m_widgets[stationID]->setWeatherIcon(dcopCall.call("currentIcon(TQString)", stationID ,true ));
@@ -134,7 +134,7 @@ void KonqSidebarWeather::update()
TQStringList replyList = reply;
for(int i = 0; i < replyList.size(); i++)
{
- if(!m_widgets.find(replyList[i]))
+ if(!m_widgets.tqfind(replyList[i]))
{
dockwidget *d = new dockwidget(m_container->viewport(), replyList[i].latin1());
m_container->addWidget(d, replyList[i].latin1());
diff --git a/kweather/weatherbar.h b/kweather/weatherbar.h
index 3f715c5..cd8cb47 100644
--- a/kweather/weatherbar.h
+++ b/kweather/weatherbar.h
@@ -19,8 +19,8 @@
* $Id$
*/
-#ifndef __KONQSIDEBARWEATHER_H__
-#define __KONQSIDEBARWEATHER_H__
+#ifndef __KONTQSIDEBARWEATHER_H__
+#define __KONTQSIDEBARWEATHER_H__
#include <konqsidebarplugin.h>
#include <kparts/part.h>
@@ -37,9 +37,10 @@ class sidebarwidget;
class KonqSidebarWeather: public KonqSidebarPlugin, virtual public DCOPObject
{
Q_OBJECT
+ TQ_OBJECT
K_DCOP
public:
- KonqSidebarWeather(KInstance* inst, TQObject* parent, TQWidget* widgetParent,
+ KonqSidebarWeather(KInstance* inst, TQObject* tqparent, TQWidget* widgetParent,
TQString& desktopName_, const char* name = 0);
~KonqSidebarWeather();
diff --git a/kweather/weatherbutton.cpp b/kweather/weatherbutton.cpp
index 3cbdebe..cc3c145 100644
--- a/kweather/weatherbutton.cpp
+++ b/kweather/weatherbutton.cpp
@@ -29,8 +29,8 @@
#include <kipc.h>
#include <kstandarddirs.h>
-WeatherButton::WeatherButton( TQWidget *parent, const char *name )
- : TQButton( parent, name ), m_highlight( false )
+WeatherButton::WeatherButton( TQWidget *tqparent, const char *name )
+ : TQButton( tqparent, name ), m_highlight( false )
{
setBackgroundOrigin( AncestorOrigin );
@@ -98,7 +98,7 @@ void WeatherButton::generateIcons()
return;
TQImage image = pixmap()->convertToImage();
- image = image.smoothScale( pixmapSize(), TQImage::ScaleMin );
+ image = image.smoothScale( pixmapSize(), TQ_ScaleMin );
KIconEffect effect;
@@ -124,14 +124,14 @@ void WeatherButton::slotIconChanged( int group )
return;
generateIcons();
- repaint( false );
+ tqrepaint( false );
}
void WeatherButton::enterEvent( TQEvent *e )
{
m_highlight = true;
- repaint( false );
+ tqrepaint( false );
TQButton::enterEvent( e );
}
@@ -139,7 +139,7 @@ void WeatherButton::leaveEvent( TQEvent *e )
{
m_highlight = false;
- repaint( false );
+ tqrepaint( false );
TQButton::enterEvent( e );
}
diff --git a/kweather/weatherbutton.h b/kweather/weatherbutton.h
index 59f6f88..fd060fe 100644
--- a/kweather/weatherbutton.h
+++ b/kweather/weatherbutton.h
@@ -23,12 +23,13 @@
#include <tqbutton.h>
#include <tqpixmap.h>
-class WeatherButton : public QButton
+class WeatherButton : public TQButton
{
Q_OBJECT
+ TQ_OBJECT
public:
- WeatherButton( TQWidget *parent, const char *name );
+ WeatherButton( TQWidget *tqparent, const char *name );
void setPixmap( const TQPixmap &pix );
protected:
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;
diff --git a/kweather/weatherlib.h b/kweather/weatherlib.h
index 5b4e92f..b745b26 100644
--- a/kweather/weatherlib.h
+++ b/kweather/weatherlib.h
@@ -29,14 +29,15 @@ namespace KIO
class StationDatabase;
-class WeatherLib : public QObject
+class WeatherLib : public TQObject
{
Q_OBJECT
+ TQ_OBJECT
public:
class Data;
- WeatherLib(StationDatabase *stationDB, TQObject *parent =0L, const char *name =0L);
+ WeatherLib(StationDatabase *stationDB, TQObject *tqparent =0L, const char *name =0L);
virtual ~WeatherLib();
TQString temperature(const TQString &stationID);
diff --git a/kweather/weatherservice.cpp b/kweather/weatherservice.cpp
index da179b6..c45315f 100644
--- a/kweather/weatherservice.cpp
+++ b/kweather/weatherservice.cpp
@@ -31,7 +31,7 @@
#include "stationdatabase.h"
#include "sun.h"
-WeatherService::WeatherService(TQObject *parent, const char *name) : TQObject (parent, name), DCOPObject("WeatherService")
+WeatherService::WeatherService(TQObject *tqparent, const char *name) : TQObject (tqparent, name), DCOPObject("WeatherService")
{
kdDebug(12006) << "Starting new service... " << endl;
diff --git a/kweather/weatherservice.h b/kweather/weatherservice.h
index 6266087..81235cd 100644
--- a/kweather/weatherservice.h
+++ b/kweather/weatherservice.h
@@ -32,6 +32,7 @@ class StationDatabase;
class WeatherService : public TQObject, public DCOPObject
{
Q_OBJECT
+// TQ_OBJECT
K_DCOP
private:
@@ -43,7 +44,7 @@ class WeatherService : public TQObject, public DCOPObject
void slotStationRemoved(const TQString &stationID);
public:
- WeatherService(TQObject *parent, const char *name);
+ WeatherService(TQObject *tqparent, const char *name);
~WeatherService();
k_dcop_signals: