Fixed two-finger touch delay, and all other hidden event-pile-up.

Added a processEvents() call in the idle, because otherwise calling idle updates starves the event handlers.
This commit is contained in:
Eric Johnston 2013-07-03 11:37:38 -07:00
parent 010fe7fadd
commit acef2bc669

View file

@ -946,6 +946,11 @@ void Application::idle() {
// Only run simulation code if more than IDLE_SIMULATE_MSECS have passed since last time we ran
if (diffclock(&_lastTimeIdle, &check) > IDLE_SIMULATE_MSECS) {
// We call processEvents() here because the idle timer takes priority over
// event handling in Qt, so when the framerate gets low events will pile up
// unless we handle them here.
processEvents();
update(1.0f / _fps);
_glWidget->updateGL();