diff options
-rw-r--r-- | mkspecs/linux-g++-maemo/qplatformdefs.h | 2 | ||||
-rw-r--r-- | src/gui/kernel/qapplication.cpp | 4 | ||||
-rw-r--r-- | src/gui/kernel/qapplication_x11.cpp | 4 |
3 files changed, 8 insertions, 2 deletions
diff --git a/mkspecs/linux-g++-maemo/qplatformdefs.h b/mkspecs/linux-g++-maemo/qplatformdefs.h index 7e8d1d4..d7feb9e 100644 --- a/mkspecs/linux-g++-maemo/qplatformdefs.h +++ b/mkspecs/linux-g++-maemo/qplatformdefs.h @@ -40,3 +40,5 @@ ****************************************************************************/ #include "../linux-g++/qplatformdefs.h" + +#define QT_GUI_DOUBLE_CLICK_RADIUS 20 diff --git a/src/gui/kernel/qapplication.cpp b/src/gui/kernel/qapplication.cpp index 4fe3900..6dda961 100644 --- a/src/gui/kernel/qapplication.cpp +++ b/src/gui/kernel/qapplication.cpp @@ -117,6 +117,10 @@ extern bool qt_wince_is_pocket_pc(); //qguifunctions_wince.cpp #include <private/qt_cocoa_helpers_mac_p.h> #endif +#ifndef QT_GUI_DOUBLE_CLICK_RADIUS +#define QT_GUI_DOUBLE_CLICK_RADIUS 5 +#endif + //#define ALIEN_DEBUG static void initResources() diff --git a/src/gui/kernel/qapplication_x11.cpp b/src/gui/kernel/qapplication_x11.cpp index afd927b..15761f4 100644 --- a/src/gui/kernel/qapplication_x11.cpp +++ b/src/gui/kernel/qapplication_x11.cpp @@ -4215,8 +4215,8 @@ bool QETWidget::translateMouseEvent(const XEvent *event) mouseButtonPressed == button && (long)event->xbutton.time -(long)mouseButtonPressTime < QApplication::doubleClickInterval() && - qAbs(event->xbutton.x - mouseXPos) < 5 && - qAbs(event->xbutton.y - mouseYPos) < 5) { + qAbs(event->xbutton.x - mouseXPos) < QT_GUI_DOUBLE_CLICK_RADIUS && + qAbs(event->xbutton.y - mouseYPos) < QT_GUI_DOUBLE_CLICK_RADIUS) { type = QEvent::MouseButtonDblClick; mouseButtonPressTime -= 2000; // no double-click next time } else { |