diff options
| author | Tor Arne Vestbø <tor.arne.vestbo@digia.com> | 2013-09-02 19:43:16 +0200 |
|---|---|---|
| committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-09-12 16:47:54 +0200 |
| commit | 5d926657f4149cde9aaa447808785abda835147f (patch) | |
| tree | d523245019f3f491bc171d6aa79acc2e83ac75ca /src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp | |
| parent | 880b614c8ffd530251b9383e085ba094a1edbca8 (diff) | |
iOS: Teach event-dispatcher to handle changes to run-loop mode at runtime
UIKit changes the run-loop mode during scrolling to UITrackingMode, which
presumably prioritizes touch events and other sources related to a
smooth scrolling experience. It signals this change by interrupting the
current run-loop pass, and the outer loop is responsible for re-entering
the run-loop in the new mode. Failing to enter the run-loop with this
new mode results in UIScrollViews losing their kinetic feel when
flicking. This can be observed by e.g. bringing up the Emoji keyboard
and scrolling it horizontally.
We keep track of the current run-loop mode by listening for push and pop
notifications on the UIApplication object. The current mode is then used
in our Q_FOREVER-loop when re-entering CFRunLoopRunInMode.
For now we don't add our posted event source or timer source to the
new modes, under the assumption that the system prefers to limit the
number of sources that will fire during scrolling. If this turns out
to give a bad user-experience for Qt applications we should consider
changing it.
Change-Id: I3a612b3cfc77c74b658963057732dc4d61684df8
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
Diffstat (limited to 'src/platformsupport/fontdatabases/basic/qbasicfontdatabase.cpp')
0 files changed, 0 insertions, 0 deletions
