aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorAlyssa Milburn2011-08-12 20:57:38 +0200
committerAlyssa Milburn2011-08-12 20:58:08 +0200
commit5d416e7903cd6fb6efa7e6dbdd0bd91aa3fc4de0 (patch)
treea2d804eb2896dadb62dd7053b99e1a29241ba91f /engines
parent26befa4b40dd230d51be756d189b92517c94720c (diff)
downloadscummvm-rg350-5d416e7903cd6fb6efa7e6dbdd0bd91aa3fc4de0.tar.gz
scummvm-rg350-5d416e7903cd6fb6efa7e6dbdd0bd91aa3fc4de0.tar.bz2
scummvm-rg350-5d416e7903cd6fb6efa7e6dbdd0bd91aa3fc4de0.zip
COMPOSER: Don't ignore setCursorVisible when there's no cursor yet.
Diffstat (limited to 'engines')
-rw-r--r--engines/composer/composer.cpp9
1 files changed, 4 insertions, 5 deletions
diff --git a/engines/composer/composer.cpp b/engines/composer/composer.cpp
index cf773dc2dc..11bf8e8900 100644
--- a/engines/composer/composer.cpp
+++ b/engines/composer/composer.cpp
@@ -253,16 +253,15 @@ void ComposerEngine::setCursor(uint16 id, const Common::Point &offset) {
}
void ComposerEngine::setCursorVisible(bool visible) {
- if (!_mouseSpriteId)
- return;
-
if (visible && !_mouseVisible) {
_mouseVisible = true;
- addSprite(_mouseSpriteId, 0, 0, _lastMousePos - _mouseOffset);
+ if (_mouseSpriteId)
+ addSprite(_mouseSpriteId, 0, 0, _lastMousePos - _mouseOffset);
onMouseMove(_lastMousePos);
} else if (!visible && _mouseVisible) {
_mouseVisible = false;
- removeSprite(_mouseSpriteId, 0);
+ if (_mouseSpriteId)
+ removeSprite(_mouseSpriteId, 0);
}
}