Skip to content
Snippets Groups Projects
Commit b5f6361d authored by Thomas Hartmann's avatar Thomas Hartmann
Browse files

QmlDesigner: fix for QTime


We have to call start() for QTime.
Calling elapsed() without calling start before
was never defined.

Change-Id: I229b3cbb30a2b3e5e98fdb05736ee0f37ae42c38
Reviewed-by: default avatarThomas Hartmann <Thomas.Hartmann@digia.com>
parent 8eabfcbb
No related branches found
No related tags found
No related merge requests found
......@@ -270,9 +270,16 @@ void FormEditorScene::mousePressEvent(QGraphicsSceneMouseEvent *event)
}
}
static QTime staticTimer()
{
QTime timer;
timer.start();
return timer;
}
void FormEditorScene::mouseMoveEvent(QGraphicsSceneMouseEvent *event)
{
static QTime time;
static QTime time = staticTimer();
if (time.elapsed() > 30) {
time.restart();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment