diff options
author | Mikolaj Boc <mikolaj.boc@qt.io> | 2022-09-05 15:55:10 +0200 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2022-09-07 07:42:09 +0000 |
commit | f19f512d5e8f12f15fea6f216762af0bba1b4e4b (patch) | |
tree | 5ab8ae314c21522577b7fde36d29bf29d2f230ea /src | |
parent | 17df321f1db187505e1204af6157742e4a633010 (diff) |
Clear the timer target time when stopping a timer on WASM
Not clearing the target time makes the subsequently created timers not
get their time ticks, as no actual timeout will be registered as the
dispatcher wrongly assumes there will be a tick fired, which there isn't.
Since there are no updates, the WASM compositor enters an infinite
window update loop where it requests an update on a window, and the
window requests an update on it, getting the update request back due to
an animation running forever.
Fixes: QTBUG-105347
Fixes: QTBUG-102004
Fixes: QTBUG-104518
Fixes: QTBUG-106153
Change-Id: I14b8dd08df81852e28e8527545c8530e0656990d
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
(cherry picked from commit df4be707407685d9afdeacaca172c01dd74c07a8)
Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
Diffstat (limited to 'src')
-rw-r--r-- | src/corelib/kernel/qeventdispatcher_wasm.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/corelib/kernel/qeventdispatcher_wasm.cpp b/src/corelib/kernel/qeventdispatcher_wasm.cpp index 7ae29e616d..73f468aae5 100644 --- a/src/corelib/kernel/qeventdispatcher_wasm.cpp +++ b/src/corelib/kernel/qeventdispatcher_wasm.cpp @@ -495,6 +495,7 @@ void QEventDispatcherWasm::updateNativeTimer() if (m_timerId > 0) { emscripten_clear_timeout(m_timerId); m_timerId = 0; + m_timerTargetTime = 0; } return; } |