diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:25:18 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:25:18 +0000 |
commit | aa3a1ca934bc541bddd3fa136a85f106f7da266e (patch) | |
tree | 9ad0b795aed8fa4ac30c2fe0fd1aacb8175714c0 /ksysv/SpinBox.cpp | |
parent | b10cf7066791a2f362495890cd50c984e8025412 (diff) | |
download | tdeadmin-aa3a1ca934bc541bddd3fa136a85f106f7da266e.tar.gz tdeadmin-aa3a1ca934bc541bddd3fa136a85f106f7da266e.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdeadmin@1157635 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'ksysv/SpinBox.cpp')
-rw-r--r-- | ksysv/SpinBox.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/ksysv/SpinBox.cpp b/ksysv/SpinBox.cpp index 63a217a..fd93954 100644 --- a/ksysv/SpinBox.cpp +++ b/ksysv/SpinBox.cpp @@ -1,14 +1,14 @@ // (c) 2000 Peter Putzer -#include <qlineedit.h> +#include <tqlineedit.h> #include <kdebug.h> #include "ksv_core.h" #include "SpinBox.h" -KSVSpinBox::KSVSpinBox (QWidget* parent, const char* name) - : QSpinBox (0, 99, 1, parent, name), +KSVSpinBox::KSVSpinBox (TQWidget* parent, const char* name) + : TQSpinBox (0, 99, 1, parent, name), KCompletionBase (), mClearedSelection (false) { @@ -17,19 +17,19 @@ KSVSpinBox::KSVSpinBox (QWidget* parent, const char* name) editor()->installEventFilter (this); - connect (editor(), SIGNAL (textChanged (const QString&)), - comp, SLOT (slotMakeCompletion (const QString&))); - connect (comp, SIGNAL (match (const QString&)), - this, SLOT (handleMatch (const QString&))); + connect (editor(), TQT_SIGNAL (textChanged (const TQString&)), + comp, TQT_SLOT (slotMakeCompletion (const TQString&))); + connect (comp, TQT_SIGNAL (match (const TQString&)), + this, TQT_SLOT (handleMatch (const TQString&))); } KSVSpinBox::~KSVSpinBox () { } -QString KSVSpinBox::mapValueToText (int value) +TQString KSVSpinBox::mapValueToText (int value) { - QString result; + TQString result; if (value < 10) result.sprintf("%.2i", value); @@ -39,9 +39,9 @@ QString KSVSpinBox::mapValueToText (int value) return result; } -void KSVSpinBox::setCompletedText (const QString& text) +void KSVSpinBox::setCompletedText (const TQString& text) { - QLineEdit* e = editor (); + TQLineEdit* e = editor (); const int pos = e->cursorPosition(); e->setText (text); @@ -50,24 +50,24 @@ void KSVSpinBox::setCompletedText (const QString& text) e->setCursorPosition (pos); } -void KSVSpinBox::setCompletedItems (const QStringList& /*items*/) +void KSVSpinBox::setCompletedItems (const TQStringList& /*items*/) { // dont know what is supposed to be in here but it has to be defined // because else the lack of this damn thing is making it abstract } -void KSVSpinBox::handleMatch (const QString& match) +void KSVSpinBox::handleMatch (const TQString& match) { if (!match.isNull() && editor()->text().length() < 2 && !mClearedSelection) setCompletedText (match); } -bool KSVSpinBox::eventFilter (QObject* o, QEvent* e) +bool KSVSpinBox::eventFilter (TQObject* o, TQEvent* e) { Q_UNUSED(o); - if (e->type() == QEvent::KeyPress) + if (e->type() == TQEvent::KeyPress) { - QKeyEvent* ke = static_cast<QKeyEvent*> (e); + TQKeyEvent* ke = static_cast<TQKeyEvent*> (e); switch (ke->key()) { |