[Scummvm-cvs-logs] SF.net SVN: scummvm: [23168] scummvm/branches/branch-0-9-0/engines/kyra/gui.cpp
vinterstum at users.sourceforge.net
vinterstum at users.sourceforge.net
Sun Jun 18 12:38:30 CEST 2006
Revision: 23168
Author: vinterstum
Date: 2006-06-18 03:38:24 -0700 (Sun, 18 Jun 2006)
ViewCVS: http://svn.sourceforge.net/scummvm/?rev=23168&view=rev
Log Message:
-----------
Makes sure updateScreen() is called once in a while in the menu polling loop, to give backends some drawing time for virtual keyboards etc
Modified Paths:
--------------
scummvm/branches/branch-0-9-0/engines/kyra/gui.cpp
Modified: scummvm/branches/branch-0-9-0/engines/kyra/gui.cpp
===================================================================
--- scummvm/branches/branch-0-9-0/engines/kyra/gui.cpp 2006-06-18 10:08:35 UTC (rev 23167)
+++ scummvm/branches/branch-0-9-0/engines/kyra/gui.cpp 2006-06-18 10:38:24 UTC (rev 23168)
@@ -806,6 +806,7 @@
void KyraEngine::gui_getInput() {
OSystem::Event event;
+ static uint32 lastScreenUpdate = 0;
uint32 now = _system->getMillis();
_mouseWheel = 0;
@@ -824,6 +825,7 @@
_mouseX = event.mouse.x;
_mouseY = event.mouse.y;
_system->updateScreen();
+ lastScreenUpdate = now;
break;
case OSystem::EVENT_WHEELUP:
_mouseWheel = -1;
@@ -844,6 +846,11 @@
}
}
+ if (now - lastScreenUpdate > 50) {
+ _system->updateScreen();
+ lastScreenUpdate = now;
+ }
+
if (!_keyboardEvent.pending && _keyboardEvent.repeat && now >= _keyboardEvent.repeat) {
_keyboardEvent.pending = true;
_keyboardEvent.repeat = now + 100;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list