aboutsummaryrefslogtreecommitdiff
path: root/engines
diff options
context:
space:
mode:
authorEugene Sandulenko2013-08-24 22:36:40 +0300
committerEugene Sandulenko2013-09-06 14:51:19 +0300
commit44081e6b1e625f5c52acf26a0336935cf99449d9 (patch)
treec6ff0a3141c3c9e76a85757c1ecc3fe6f6150791 /engines
parent3d3ebc6ae7430ae4147bdc9e07115d134dd9d312 (diff)
downloadscummvm-rg350-44081e6b1e625f5c52acf26a0336935cf99449d9.tar.gz
scummvm-rg350-44081e6b1e625f5c52acf26a0336935cf99449d9.tar.bz2
scummvm-rg350-44081e6b1e625f5c52acf26a0336935cf99449d9.zip
FULLPIPE: Implement InputController::drawCursor()
Diffstat (limited to 'engines')
-rw-r--r--engines/fullpipe/input.cpp13
1 files changed, 12 insertions, 1 deletions
diff --git a/engines/fullpipe/input.cpp b/engines/fullpipe/input.cpp
index efc42b3bc9..767a0d5c44 100644
--- a/engines/fullpipe/input.cpp
+++ b/engines/fullpipe/input.cpp
@@ -83,7 +83,18 @@ void CInputController::setCursorMode(bool enabled) {
}
void CInputController::drawCursor(int x, int y) {
- warning("STUB: CInputController::drawCursor(%d, %d)", x, y);
+ if (_cursorIndex == -1)
+ return;
+
+ _cursorBounds.left = g_fullpipe->_sceneRect.left + x - _cursorsArray[_cursorIndex]->hotspotX;
+ _cursorBounds.top = g_fullpipe->_sceneRect.top + y - _cursorsArray[_cursorIndex]->hotspotY;
+ _cursorBounds.right = _cursorBounds.left + _cursorsArray[_cursorIndex]->width;
+ _cursorBounds.bottom = _cursorBounds.top + _cursorsArray[_cursorIndex]->height;
+
+ _cursorsArray[_cursorIndex]->picture->draw(_cursorBounds.left, _cursorBounds.top, 0, 0);
+
+ if (_cursorItemPicture)
+ _cursorItemPicture->draw(_cursorsArray[_cursorIndex]->itemPictureOffsX, _cursorsArray[_cursorIndex]->itemPictureOffsY, 0, 0);
}
void CInputController::setCursor(int cursorId) {