summaryrefslogtreecommitdiffstats
path: root/kradio3/plugins/timecontrol/timecontrol-configuration.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-01 03:43:07 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-07-01 03:43:07 +0000
commit70b9eea2ba01c3691497f49e4c45cb070c16193c (patch)
tree9a6df61aa247a27275aad9c5245e419e89c2c640 /kradio3/plugins/timecontrol/timecontrol-configuration.cpp
parent998c1384ace4ae4655997c181fa33242148cd0a4 (diff)
downloadtderadio-70b9eea2ba01c3691497f49e4c45cb070c16193c.tar.gz
tderadio-70b9eea2ba01c3691497f49e4c45cb070c16193c.zip
TQt4 port kradio
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kradio@1238952 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'kradio3/plugins/timecontrol/timecontrol-configuration.cpp')
-rw-r--r--kradio3/plugins/timecontrol/timecontrol-configuration.cpp84
1 files changed, 42 insertions, 42 deletions
diff --git a/kradio3/plugins/timecontrol/timecontrol-configuration.cpp b/kradio3/plugins/timecontrol/timecontrol-configuration.cpp
index 4ea6bce..c49906d 100644
--- a/kradio3/plugins/timecontrol/timecontrol-configuration.cpp
+++ b/kradio3/plugins/timecontrol/timecontrol-configuration.cpp
@@ -19,14 +19,14 @@
#include <algorithm>
using std::sort;
-#include <qdatetime.h>
-#include <qlistbox.h>
-#include <qcombobox.h>
-#include <qdatetimeedit.h>
-#include <qlabel.h>
-#include <qspinbox.h>
-#include <qcheckbox.h>
-#include <qpushbutton.h>
+#include <tqdatetime.h>
+#include <tqlistbox.h>
+#include <tqcombobox.h>
+#include <tqdatetimeedit.h>
+#include <tqlabel.h>
+#include <tqspinbox.h>
+#include <tqcheckbox.h>
+#include <tqpushbutton.h>
#include <klistbox.h>
#include <klocale.h>
@@ -47,37 +47,37 @@ public:
};
-TimeControlConfiguration::TimeControlConfiguration (QWidget *parent)
- : TimeControlConfigurationUI(parent),
+TimeControlConfiguration::TimeControlConfiguration (TQWidget *tqparent)
+ : TimeControlConfigurationUI(tqparent),
ITimeControlClient(),
IRadioClient(),
ignoreChanges(false),
m_dirty(false)
{
- QObject::connect(checkboxAlarmDaily, SIGNAL(toggled(bool)), this, SLOT(slotDailyChanged(bool)));
- QObject::connect(listWeekdays, SIGNAL(highlighted(int)), this, SLOT(slotWeekdaysChanged()));
- QObject::connect(checkboxAlarmEnable, SIGNAL(toggled(bool)), this, SLOT(slotEnabledChanged(bool)));
- QObject::connect(comboStationSelection, SIGNAL(highlighted(int)), this, SLOT(slotStationChanged(int)));
- QObject::connect(listAlarms, SIGNAL(highlighted(int)), this, SLOT(slotAlarmSelectChanged(int)));
- QObject::connect(editAlarmDate, SIGNAL(valueChanged(const QDate &)), this, SLOT(slotDateChanged(const QDate &)));
- QObject::connect(editAlarmTime, SIGNAL(valueChanged(const QTime &)), this, SLOT(slotTimeChanged(const QTime &)));
- QObject::connect(editAlarmVolume, SIGNAL(valueChanged(int)), this, SLOT(slotVolumeChanged(int)));
- QObject::connect(buttonAlarmNew, SIGNAL(clicked()), this, SLOT(slotNewAlarm()));
- QObject::connect(buttonDeleteAlarm, SIGNAL(clicked()), this, SLOT(slotDeleteAlarm()));
- QObject::connect(comboAlarmType, SIGNAL(highlighted(int)), this, SLOT(slotAlarmTypeChanged(int)));
-
- QObject::connect(checkboxAlarmDaily, SIGNAL(toggled(bool)), this, SLOT(slotSetDirty()));
- QObject::connect(listWeekdays, SIGNAL(selectionChanged()), this, SLOT(slotSetDirty()));
- QObject::connect(checkboxAlarmEnable, SIGNAL(toggled(bool)), this, SLOT(slotSetDirty()));
- QObject::connect(comboStationSelection, SIGNAL(activated(int)), this, SLOT(slotSetDirty()));
- QObject::connect(editAlarmDate, SIGNAL(valueChanged(const QDate &)), this, SLOT(slotSetDirty()));
- QObject::connect(editAlarmTime, SIGNAL(valueChanged(const QTime &)), this, SLOT(slotSetDirty()));
- QObject::connect(editAlarmVolume, SIGNAL(valueChanged(int)), this, SLOT(slotSetDirty()));
- QObject::connect(buttonAlarmNew, SIGNAL(clicked()), this, SLOT(slotSetDirty()));
- QObject::connect(buttonDeleteAlarm, SIGNAL(clicked()), this, SLOT(slotSetDirty()));
- QObject::connect(comboAlarmType, SIGNAL(activated(int)), this, SLOT(slotSetDirty()));
- QObject::connect(editSleep, SIGNAL(valueChanged(int)), this, SLOT(slotSetDirty()));
+ TQObject::connect(checkboxAlarmDaily, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotDailyChanged(bool)));
+ TQObject::connect(listWeekdays, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(slotWeekdaysChanged()));
+ TQObject::connect(checkboxAlarmEnable, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotEnabledChanged(bool)));
+ TQObject::connect(comboStationSelection, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(slotStationChanged(int)));
+ TQObject::connect(listAlarms, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(slotAlarmSelectChanged(int)));
+ TQObject::connect(editAlarmDate, TQT_SIGNAL(valueChanged(const TQDate &)), this, TQT_SLOT(slotDateChanged(const TQDate &)));
+ TQObject::connect(editAlarmTime, TQT_SIGNAL(valueChanged(const TQTime &)), this, TQT_SLOT(slotTimeChanged(const TQTime &)));
+ TQObject::connect(editAlarmVolume, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotVolumeChanged(int)));
+ TQObject::connect(buttonAlarmNew, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotNewAlarm()));
+ TQObject::connect(buttonDeleteAlarm, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotDeleteAlarm()));
+ TQObject::connect(comboAlarmType, TQT_SIGNAL(highlighted(int)), this, TQT_SLOT(slotAlarmTypeChanged(int)));
+
+ TQObject::connect(checkboxAlarmDaily, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(listWeekdays, TQT_SIGNAL(selectionChanged()), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(checkboxAlarmEnable, TQT_SIGNAL(toggled(bool)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(comboStationSelection, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(editAlarmDate, TQT_SIGNAL(valueChanged(const TQDate &)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(editAlarmTime, TQT_SIGNAL(valueChanged(const TQTime &)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(editAlarmVolume, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(buttonAlarmNew, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(buttonDeleteAlarm, TQT_SIGNAL(clicked()), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(comboAlarmType, TQT_SIGNAL(activated(int)), this, TQT_SLOT(slotSetDirty()));
+ TQObject::connect(editSleep, TQT_SIGNAL(valueChanged(int)), this, TQT_SLOT(slotSetDirty()));
}
TimeControlConfiguration::~TimeControlConfiguration ()
@@ -140,7 +140,7 @@ bool TimeControlConfiguration::noticeNextAlarmChanged(const Alarm *)
return true;
}
-bool TimeControlConfiguration::noticeCountdownStarted(const QDateTime &/*end*/)
+bool TimeControlConfiguration::noticeCountdownStarted(const TQDateTime &/*end*/)
{
return false;
}
@@ -179,7 +179,7 @@ bool TimeControlConfiguration::noticeStationsChanged(const StationList &sl)
comboStationSelection->clear();
stationIDs.clear();
comboStationSelection->insertItem(i18n("<don't change>"));
- stationIDs.push_back(QString::null);
+ stationIDs.push_back(TQString());
for (RawStationList::Iterator i(sl.all()); i.current(); ++i) {
comboStationSelection->insertItem(i.current()->iconName(),
@@ -193,7 +193,7 @@ bool TimeControlConfiguration::noticeStationsChanged(const StationList &sl)
// Slots
-void TimeControlConfiguration::slotDateChanged( const QDate &d )
+void TimeControlConfiguration::slotDateChanged( const TQDate &d )
{
if (ignoreChanges) return;
@@ -212,7 +212,7 @@ void TimeControlConfiguration::slotDateChanged( const QDate &d )
}
-void TimeControlConfiguration::slotTimeChanged(const QTime &t)
+void TimeControlConfiguration::slotTimeChanged(const TQTime &t)
{
if (ignoreChanges) return;
@@ -258,17 +258,17 @@ void TimeControlConfiguration::slotWeekdaysChanged ()
{
if (ignoreChanges) return;
- int mask = 0;
+ int tqmask = 0;
for (int i = 0; i < 7; ++i) {
if (listWeekdays->isSelected(i)) {
- mask |= (1 << i);
+ tqmask |= (1 << i);
}
}
int idx = listAlarms->currentItem();
if (idx >= 0 && (unsigned)idx < alarms.size()) {
Alarm &a = alarms[idx];
- a.setWeekdayMask(mask);
+ a.setWeekdayMask(tqmask);
ignoreChanges = true;
bool oldBlock = listAlarms->signalsBlocked();
@@ -355,7 +355,7 @@ void TimeControlConfiguration::slotAlarmSelectChanged(int idx)
comboAlarmType ->setCurrentItem(a.alarmType());
int k = 0;
- const QString &sID = a.stationID();
+ const TQString &sID = a.stationID();
for (int i = 0; !k && i < (int)stationIDs.size(); ++i)
if (stationIDs[i] == sID) k = i;
comboStationSelection->setCurrentItem(k);
@@ -371,7 +371,7 @@ void TimeControlConfiguration::slotAlarmSelectChanged(int idx)
void TimeControlConfiguration::slotNewAlarm()
{
- QDateTime dt(QDateTime::currentDateTime());
+ TQDateTime dt(TQDateTime::tqcurrentDateTime());
Alarm a(dt, false, false);
alarms.push_back(a);
listAlarms->insertItem(a.alarmTime().toString());