[Scummvm-cvs-logs] SF.net SVN: scummvm:[39975] scummvm/trunk/engines/kyra/kyra_v1.cpp
eriktorbjorn at users.sourceforge.net
eriktorbjorn at users.sourceforge.net
Sat Apr 18 05:15:35 CEST 2009
Revision: 39975
http://scummvm.svn.sourceforge.net/scummvm/?rev=39975&view=rev
Author: eriktorbjorn
Date: 2009-04-18 03:15:34 +0000 (Sat, 18 Apr 2009)
Log Message:
-----------
We probably only have to update the screen once every updateInfo(). And, since
it's triggered by mouse movements, only when the cursor is visible.
Modified Paths:
--------------
scummvm/trunk/engines/kyra/kyra_v1.cpp
Modified: scummvm/trunk/engines/kyra/kyra_v1.cpp
===================================================================
--- scummvm/trunk/engines/kyra/kyra_v1.cpp 2009-04-17 22:18:48 UTC (rev 39974)
+++ scummvm/trunk/engines/kyra/kyra_v1.cpp 2009-04-18 03:15:34 UTC (rev 39975)
@@ -375,6 +375,8 @@
void KyraEngine_v1::updateInput() {
Common::Event event;
+ bool updateScreen = false;
+
while (_eventMan->pollEvent(event)) {
switch (event.type) {
case Common::EVENT_KEYDOWN:
@@ -395,7 +397,8 @@
break;
case Common::EVENT_MOUSEMOVE:
- screen()->updateScreen();
+ if (screen()->isMouseVisible())
+ updateScreen = true;
// fall through
case Common::EVENT_LBUTTONUP:
@@ -409,6 +412,9 @@
break;
}
}
+
+ if (updateScreen)
+ screen()->updateScreen();
}
void KyraEngine_v1::removeInputTop() {
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