From 252fce5a2a5384702fbcc1c9987284d7bd2e6943 Mon Sep 17 00:00:00 2001 From: Timothy Pearson Date: Thu, 15 Dec 2011 15:31:01 -0600 Subject: Rename a number of old tq methods that are no longer tq specific --- kmymoney2/widgets/kmymoneydateinput.cpp | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) (limited to 'kmymoney2/widgets/kmymoneydateinput.cpp') diff --git a/kmymoney2/widgets/kmymoneydateinput.cpp b/kmymoney2/widgets/kmymoneydateinput.cpp index 37db28b..59c838c 100644 --- a/kmymoney2/widgets/kmymoneydateinput.cpp +++ b/kmymoney2/widgets/kmymoneydateinput.cpp @@ -24,7 +24,7 @@ #include #include #include -#include +#include #include #include #include @@ -72,12 +72,12 @@ bool KMyMoneyDateEdit::event(TQEvent* e) kMyMoneyDateInput::kMyMoneyDateInput(TQWidget *parent, const char *name, TQt::AlignmentFlags flags) : TQHBox(parent,name) { - m_qttqalignment = flags; - m_date = TQDate::tqcurrentDate(); + m_qtalignment = flags; + m_date = TQDate::currentDate(); dateEdit = new KMyMoneyDateEdit(m_date, this, "dateEdit"); setFocusProxy(dateEdit); - tqfocusWidget()->installEventFilter(this); // To get dateEdit's FocusIn/Out and some KeyPress events + focusWidget()->installEventFilter(this); // To get dateEdit's FocusIn/Out and some KeyPress events dateEdit->installEventFilter(this); // To get dateEdit's FocusIn/Out and some KeyPress events m_datePopup = new KPassivePopup(dateEdit, "datePopup"); @@ -165,13 +165,13 @@ void kMyMoneyDateInput::show(void) void kMyMoneyDateInput::fixSize(void) { - // According to a hint in the documentation of KDatePicker::tqsizeHint() + // According to a hint in the documentation of KDatePicker::sizeHint() // 28 pixels should be added in each direction to obtain a better // display of the month button. I decided, (22,14) is good // enough and save some space on the screen (ipwizard) - m_dateFrame->setFixedSize(m_datePicker->tqsizeHint() + TQSize(22, 14)); + m_dateFrame->setFixedSize(m_datePicker->sizeHint() + TQSize(22, 14)); - dateEdit->setMinimumWidth(dateEdit->tqminimumSizeHint().width() + 6); + dateEdit->setMinimumWidth(dateEdit->minimumSizeHint().width() + 6); } kMyMoneyDateInput::~kMyMoneyDateInput() @@ -191,7 +191,7 @@ void kMyMoneyDateInput::toggleDatePicker() } else { - TQPoint tmpPoint = mapToGlobal(m_dateButton->tqgeometry().bottomRight()); + TQPoint tmpPoint = mapToGlobal(m_dateButton->geometry().bottomRight()); // usually, the datepicker widget is shown underneath the dateEdit widget // if it does not fit on the screen, we show it above this widget @@ -200,7 +200,7 @@ void kMyMoneyDateInput::toggleDatePicker() tmpPoint.setY(tmpPoint.y() - h - m_dateButton->height()); } - if((m_qttqalignment == TQt::AlignRight && tmpPoint.x()+w <= TQApplication::desktop()->width()) + if((m_qtalignment == TQt::AlignRight && tmpPoint.x()+w <= TQApplication::desktop()->width()) || (tmpPoint.x()-w < 0) ) { m_dateFrame->setGeometry(tmpPoint.x()-width(), tmpPoint.y(), w, h); @@ -217,7 +217,7 @@ void kMyMoneyDateInput::toggleDatePicker() } else { - m_datePicker->setDate(TQDate::tqcurrentDate()); + m_datePicker->setDate(TQDate::currentDate()); } m_dateFrame->show(); } @@ -255,14 +255,14 @@ void kMyMoneyDateInput::keyPressEvent(TQKeyEvent * k) default: if(today.contains(KKey(k)) || k->key() == Key_T) { - slotDateChosen(TQDate::tqcurrentDate()); + slotDateChosen(TQDate::currentDate()); } break; } } /** - * This function receives all events that are sent to tqfocusWidget(). + * This function receives all events that are sent to focusWidget(). * Some KeyPress events are intercepted and passed to keyPressEvent. * Otherwise they would be consumed by TQDateEdit. */ @@ -337,7 +337,7 @@ void kMyMoneyDateInput::resetDate(void) setDate(m_prevDate); } -TQWidget* kMyMoneyDateInput::tqfocusWidget(void) const +TQWidget* kMyMoneyDateInput::focusWidget(void) const { TQWidget* w = dateEdit; while(w->focusProxy()) -- cgit v1.2.1