Commit 993647db authored by Pablo Rauzy's avatar Pablo Rauzy Committed by Christoph Cullmann
Browse files

small optimization: don't bother processing all events immediatly if no...

small optimization: don't bother processing all events immediatly if no complex GUI update (like adding a widget) are expected
parent 68e8a3b1
......@@ -297,8 +297,10 @@ bool KeyboardMacrosPlugin::play(const QString &name)
// send key release
QKeyEvent keyRelease = keyCombination.keyRelease();
qApp->sendEvent(qApp->focusWidget(), &keyRelease);
// process events
qApp->processEvents(QEventLoop::AllEvents);
// process events immediately if a shortcut may have been triggered
if (!keyCombination.isVisibleInput()) {
qApp->processEvents(QEventLoop::AllEvents);
}
}
return true;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment