summaryrefslogtreecommitdiffstats
path: root/libkdeedu/extdate/extdatewidget.cpp
diff options
context:
space:
mode:
authortpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-11 04:44:41 +0000
committertpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da>2011-06-11 04:44:41 +0000
commita374efce3a207b39514be3c52264091400ce297e (patch)
tree77bdf654b55826d4f59b53a5621310206bcaead1 /libkdeedu/extdate/extdatewidget.cpp
parentf81a494f3957d5cf38c787973415597941934727 (diff)
downloadtdeedu-a374efce3a207b39514be3c52264091400ce297e.tar.gz
tdeedu-a374efce3a207b39514be3c52264091400ce297e.zip
TQt4 port kdeedu
This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeedu@1236073 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'libkdeedu/extdate/extdatewidget.cpp')
-rw-r--r--libkdeedu/extdate/extdatewidget.cpp32
1 files changed, 16 insertions, 16 deletions
diff --git a/libkdeedu/extdate/extdatewidget.cpp b/libkdeedu/extdate/extdatewidget.cpp
index 5f5d19d6..f787293f 100644
--- a/libkdeedu/extdate/extdatewidget.cpp
+++ b/libkdeedu/extdate/extdatewidget.cpp
@@ -30,13 +30,13 @@
#include "extdatewidget.h"
#include "extcalendarsystemgregorian.h"
-class ExtDateWidgetSpinBox : public QSpinBox
+class ExtDateWidgetSpinBox : public TQSpinBox
{
public:
- ExtDateWidgetSpinBox(int min, int max, TQWidget *parent)
- : TQSpinBox(min, max, 1, parent)
+ ExtDateWidgetSpinBox(int min, int max, TQWidget *tqparent)
+ : TQSpinBox(min, max, 1, tqparent)
{
- editor()->setAlignment(AlignRight);
+ editor()->tqsetAlignment(AlignRight);
}
};
@@ -53,16 +53,16 @@ public:
};
-ExtDateWidget::ExtDateWidget( TQWidget *parent, const char *name )
- : TQWidget( parent, name )
+ExtDateWidget::ExtDateWidget( TQWidget *tqparent, const char *name )
+ : TQWidget( tqparent, name )
{
- init(ExtDate::currentDate());
+ init(ExtDate::tqcurrentDate());
setDate(ExtDate());
}
-ExtDateWidget::ExtDateWidget( const ExtDate &date, TQWidget *parent,
+ExtDateWidget::ExtDateWidget( const ExtDate &date, TQWidget *tqparent,
const char *name )
- : TQWidget( parent, name )
+ : TQWidget( tqparent, name )
{
init(date);
setDate(date);
@@ -74,8 +74,8 @@ ExtDateWidget::ExtDateWidget( const ExtDate &date, TQWidget *parent,
// {
// d = new ExtDateWidgetPrivate;
// KLocale *locale = KGlobal::locale();
-// TQHBoxLayout *layout = new TQHBoxLayout(this, 0, KDialog::spacingHint());
-// layout->setAutoAdd(true);
+// TQHBoxLayout *tqlayout = new TQHBoxLayout(this, 0, KDialog::spacingHint());
+// tqlayout->setAutoAdd(true);
// d->m_day = new ExtDateWidgetSpinBox(1, 1, this);
// d->m_month = new TQComboBox(false, this);
// for (int i = 1; ; ++i)
@@ -98,8 +98,8 @@ void ExtDateWidget::init(const ExtDate& date)
{
d = new ExtDateWidgetPrivate;
//KLocale *locale = KGlobal::locale();
- TQHBoxLayout *layout = new TQHBoxLayout(this, 0, KDialog::spacingHint());
- layout->setAutoAdd(true);
+ TQHBoxLayout *tqlayout = new TQHBoxLayout(this, 0, KDialog::spacingHint());
+ tqlayout->setAutoAdd(true);
d->m_day = new ExtDateWidgetSpinBox(1, 1, this);
d->m_month = new TQComboBox(false, this);
for (int i = 1; ; ++i)
@@ -157,15 +157,15 @@ void ExtDateWidget::slotDateChanged( )
int y,m,day;
y = d->m_year->value();
- y = QMIN(QMAX(y, d->calendar->minValidYear()), d->calendar->maxValidYear());
+ y = TQMIN(TQMAX(y, d->calendar->minValidYear()), d->calendar->maxValidYear());
d->calendar->setYMD(date, y, 1, 1);
m = d->m_month->currentItem()+1;
- m = QMIN(QMAX(m,1), d->calendar->monthsInYear(date));
+ m = TQMIN(TQMAX(m,1), d->calendar->monthsInYear(date));
d->calendar->setYMD(date, y, m, 1);
day = d->m_day->value();
- day = QMIN(QMAX(day,1), d->calendar->daysInMonth(date));
+ day = TQMIN(TQMAX(day,1), d->calendar->daysInMonth(date));
d->calendar->setYMD(date, y, m, day);
setDate(date);