diff options
author | Paul Gilbert | 2013-11-24 16:59:44 -0500 |
---|---|---|
committer | Paul Gilbert | 2013-11-24 16:59:44 -0500 |
commit | c26ed6505f4a3c12c082473a1ebaaabd32d40a88 (patch) | |
tree | c9298cf61976f89aff563f7d68ff91e514577aa9 /engines/tsage/ringworld2/ringworld2_dialogs.cpp | |
parent | bd8f260d9b128ba03131c7002d8dcf750765f208 (diff) | |
download | scummvm-rg350-c26ed6505f4a3c12c082473a1ebaaabd32d40a88.tar.gz scummvm-rg350-c26ed6505f4a3c12c082473a1ebaaabd32d40a88.tar.bz2 scummvm-rg350-c26ed6505f4a3c12c082473a1ebaaabd32d40a88.zip |
TSAGE: Fixes for R2R right click dialog choosing cursor or help/player dialog
Diffstat (limited to 'engines/tsage/ringworld2/ringworld2_dialogs.cpp')
-rw-r--r-- | engines/tsage/ringworld2/ringworld2_dialogs.cpp | 15 |
1 files changed, 9 insertions, 6 deletions
diff --git a/engines/tsage/ringworld2/ringworld2_dialogs.cpp b/engines/tsage/ringworld2/ringworld2_dialogs.cpp index 12147f7ee5..a0675bc292 100644 --- a/engines/tsage/ringworld2/ringworld2_dialogs.cpp +++ b/engines/tsage/ringworld2/ringworld2_dialogs.cpp @@ -50,6 +50,7 @@ RightClickDialog::RightClickDialog() : GfxDialog() { _btnList[5] = Common::Point(83, 47); // Set the palette and change the cursor + _previousCursor = R2_GLOBALS._events.getCursor(); R2_GLOBALS._events.setCursor(CURSOR_ARROW); setPalette(); @@ -136,7 +137,7 @@ bool RightClickDialog::process(Event &event) { return false; } -void RightClickDialog::execute() { +int RightClickDialog::execute() { // Draw the dialog draw(); @@ -157,7 +158,8 @@ void RightClickDialog::execute() { } // Execute the specified action - CursorType cursorNum = CURSOR_NONE; + CursorType cursorNum = _previousCursor; + int result = -1; switch (_selectedAction) { case 0: // Look action @@ -177,17 +179,18 @@ void RightClickDialog::execute() { break; case 4: // Change player - CharacterDialog::show(); + result = 0; break; case 5: // Options dialog + result = 1; break; } - if (cursorNum != CURSOR_NONE) - R2_GLOBALS._events.setCursor(cursorNum); - + R2_GLOBALS._events.setCursor(cursorNum); _gfxManager.deactivate(); + + return result; } /*--------------------------------------------------------------------------*/ |