diff options
author | Andrew den Exter <andrew.den-exter@nokia.com> | 2012-01-10 10:28:11 +1000 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-01-12 09:33:32 +0100 |
commit | 521aa7f562a5f215de09e3f37168f6a6d0ce5543 (patch) | |
tree | feaa4b1cdd8dc799b876ff2218434b8ad0cfe7f6 /src | |
parent | 21e6e0e6aa72ab6051eaadd5fbda29c795ca8c8e (diff) |
Fix restarting timer from onTriggered handler.
Set the running property to false before calling the triggered handler
when a timer finishes so it does not appear to still be running and
can be restarted by setting the running property to true.
Task-number: QTBUG-22004
Change-Id: I840efa30f5b7ad7d0cda96803d4898be3f390705
Reviewed-by: Martin Jones <martin.jones@nokia.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/quick/util/qdeclarativetimer.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/quick/util/qdeclarativetimer.cpp b/src/quick/util/qdeclarativetimer.cpp index 3855521545..e03094773b 100644 --- a/src/quick/util/qdeclarativetimer.cpp +++ b/src/quick/util/qdeclarativetimer.cpp @@ -315,9 +315,9 @@ void QDeclarativeTimer::finished() Q_D(QDeclarativeTimer); if (d->repeating || !d->running) return; - emit triggered(); d->running = false; d->firstTick = false; + emit triggered(); emit runningChanged(); } |