From e86f8310a920cbf1ecfac955fbad05916e954693 Mon Sep 17 00:00:00 2001 From: tpearson Date: Thu, 30 Jun 2011 19:20:52 +0000 Subject: TQt4 port knowit This enables compilation under both Qt3 and Qt4 git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/knowit@1238876 283d02a7-25f6-0310-bc7c-ecb5cbfe19da --- src/knowitlinks.cpp | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'src/knowitlinks.cpp') diff --git a/src/knowitlinks.cpp b/src/knowitlinks.cpp index daab0bb..819fa3f 100644 --- a/src/knowitlinks.cpp +++ b/src/knowitlinks.cpp @@ -16,21 +16,21 @@ ***************************************************************************/ #include "knowitlinks.h" -#include +#include #include -KnowitLinks::KnowitLinks(QWidget* parent, const char* name) - : KListBox(parent, name) +KnowitLinks::KnowitLinks(TQWidget* tqparent, const char* name) + : KListBox(tqparent, name) { setAcceptDrops(true); } -void KnowitLinks::dragEnterEvent(QDragEnterEvent* event) +void KnowitLinks::dragEnterEvent(TQDragEnterEvent* event) { event->accept(KURLDrag::canDecode(event)); } -void KnowitLinks::dropEvent(QDropEvent* event) +void KnowitLinks::dropEvent(TQDropEvent* event) { if (KURLDrag::canDecode(event)) { KURL::List L; @@ -40,15 +40,15 @@ void KnowitLinks::dropEvent(QDropEvent* event) } } -void KnowitLinks::keyPressEvent(QKeyEvent* e) +void KnowitLinks::keyPressEvent(TQKeyEvent* e) { - if (currentItem() != -1 && (e->key() == Qt::Key_Enter || e->key() == Qt::Key_Return)) { + if (currentItem() != -1 && (e->key() == TQt::Key_Enter || e->key() == TQt::Key_Return)) { e->ignore(); - if ((e->state() | Qt::NoButton | Qt::Keypad) == - (Qt::NoButton | Qt::Keypad)) emit linkOpen(); + if ((e->state() | Qt::NoButton | TQt::Keypad) == + (Qt::NoButton | TQt::Keypad)) emit linkOpen(); else emit linkOpenWith(); } - else if (currentItem() != -1 && e->key() == Qt::Key_Delete) { + else if (currentItem() != -1 && e->key() == TQt::Key_Delete) { e->ignore(); emit linkRemove(); } -- cgit v1.2.1