qt5base-lts/src/corelib
Gabriel de Dietrich f253f4c331 Track target widget when wheel events are received
This issue is reproducible on OS X when using a Magic Mouse
or a combination of Magic Trackpad and regular mouse. In these
cases it's possible to start a scrolling gesture on one widget
and move the mouse cursor over another widget.

Although we send the wheel event phase information, we never
made any use of it. This means that a widget would start
scrolling even though it never received a ScrollBegin event.

In this patch, we make sure the scrolling cycle is respected
and that once a widget starts scrolling, it'll be recieving
all the wheel events until a ScrollEnd event reaches the
application.

For those input devices not supporting a proper phase cycle,
we introduce a new (undocumented) phase value, NoScrollPhase.
If the wheel event phase is NoScrollPhase, then we ignore
the current scroll widget and proceed as usual. This value
is the default for wheel events. It's up to the platform
plugin to set the proper phase value according to the data
received from the OS.

Finally, we fix a few of QWheelEvent constructors to properly
initialize the phase and source properties.

Task-number: QTBUG-50199
Change-Id: I3773729a9c757e2d2fcc5100dcd79f0ed26cb808
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-02-29 08:19:51 +00:00
..
animation QSequentialAnimationGroupPrivate: replace an inefficient QList with QVector 2015-07-13 10:36:34 +00:00
arch Make public headers compile with -Wzero-as-null-pointer-constant 2016-02-19 16:37:33 +00:00
codecs Reduce allocations by using reserve() 2016-02-07 16:50:26 +00:00
doc [docs] Fix reverse STL iteration example 2016-01-21 05:29:32 +00:00
global Track target widget when wheel events are received 2016-02-29 08:19:51 +00:00
io OS X: Implement download folder display name query 2016-02-15 14:22:14 +00:00
itemmodels Reduce allocations by using reserve() 2016-02-07 16:50:26 +00:00
json Fix quadratic behavior when converting from QVariant 2016-02-18 07:38:37 +00:00
kernel doc: Clean up old references to QApplication for GUI application 2016-02-19 11:35:52 +00:00
mimetypes QMimeDatabase: follow symlinks when checking for FIFO etc. 2015-12-29 11:06:13 +00:00
plugin Link with -ldl option only when it is supported 2016-02-05 16:29:09 +00:00
statemachine Allow QFinalStatePrivate to be subclassed. 2016-01-28 16:24:46 +00:00
thread Merge remote-tracking branch 'origin/5.5' into 5.6 2016-01-29 11:13:41 +01:00
tools Merge remote-tracking branch 'origin/5.6.0' into 5.6 2016-02-15 08:09:50 +01:00
xml QXmlStreamStringRef: unbreak move special member functions 2015-11-19 07:40:49 +00:00
corelib.pro Fix build on FreeBSD: 'environ' is not defined in a library 2016-02-02 19:23:47 +00:00
eval.pri
Qt5Config.cmake.in
Qt5CoreConfigExtras.cmake.in CMake: Add -fPIC to CXX flags only where necessary 2015-12-28 22:39:58 +00:00
Qt5CoreConfigExtrasMkspecDir.cmake.in
Qt5CoreConfigExtrasMkspecDirForInstall.cmake.in
Qt5CoreMacros.cmake CMake: Fix qt5_use_modules macro for CMake 2.8.11 2016-01-11 09:53:32 +00:00
Qt5CTestMacros.cmake CMake: Introduce qt5_add_binary_resources 2015-02-11 20:59:35 +00:00
QtCore.dynlist
qtzlib.pro make a proper header-only module for QtZlib 2015-11-17 20:22:17 +00:00