From 0f93eff78f1396f4d55e08b1bffaf7ce557b364f Mon Sep 17 00:00:00 2001 From: Edward Welbourne Date: Wed, 12 Jun 2019 18:36:19 +0200 Subject: Convert uses of QTime as a timer to QElapsedTimer Change-Id: I19b6f439aa475c32cfe90e67adba93127e476d6e Reviewed-by: Friedemann Kleint --- src/scripttools/debugging/qscriptdebuggeragent.cpp | 2 +- src/scripttools/debugging/qscriptdebuggeragent_p_p.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/scripttools/debugging/qscriptdebuggeragent.cpp b/src/scripttools/debugging/qscriptdebuggeragent.cpp index 5642dfe..7e25304 100644 --- a/src/scripttools/debugging/qscriptdebuggeragent.cpp +++ b/src/scripttools/debugging/qscriptdebuggeragent.cpp @@ -559,7 +559,7 @@ void QScriptDebuggerAgent::positionChange(qint64 scriptId, if (engine()->processEventsInterval() == -1) { // see if it's time to call processEvents() if ((++d->statementCounter % 25000) == 0) { - if (!d->processEventsTimer.isNull()) { + if (d->processEventsTimer.isValid()) { if (d->processEventsTimer.elapsed() > 30) { QCoreApplication::processEvents(); d->processEventsTimer.restart(); diff --git a/src/scripttools/debugging/qscriptdebuggeragent_p_p.h b/src/scripttools/debugging/qscriptdebuggeragent_p_p.h index 2e8be3a..1474032 100644 --- a/src/scripttools/debugging/qscriptdebuggeragent_p_p.h +++ b/src/scripttools/debugging/qscriptdebuggeragent_p_p.h @@ -52,7 +52,7 @@ // #include -#include +#include #include #include #include @@ -113,7 +113,7 @@ public: QList checkpointContextIdStack; qint64 nextContextId; - QTime processEventsTimer; + QElapsedTimer processEventsTimer; int statementCounter; QScriptDebuggerBackendPrivate *backend; -- cgit v1.2.1