Details
-
Bug
-
Resolution: Done
-
P2: Important
-
None
-
5.3.1
-
None
Description
When using QWS it was possible to adjust the distance for detecting double clicks using env. var QWS_DBLCLICK_DISTANCE, which can be very useful on embedded devices.
Proposed patch:
diff --git a/src/gui/kernel/qplatformtheme.cpp b/src/gui/kernel/qplatformtheme.cpp index d3d3d3c..bfad486 100644 --- a/src/gui/kernel/qplatformtheme.cpp +++ b/src/gui/kernel/qplatformtheme.cpp @@ -508,6 +508,9 @@ QVariant QPlatformTheme::defaultThemeHint(ThemeHint hint) case MousePressAndHoldInterval: return QVariant(800); case MouseDoubleClickDistance: + bool ok = false; + int dist = QString(qgetenv("QT_DBL_CLICK_DIST")).toInt(&ok); + if (ok) return QVariant(dist); return QVariant(5); } return QVariant();