diff options
Diffstat (limited to 'engines')
-rw-r--r-- | engines/kyra/gui_lol.cpp | 3 | ||||
-rw-r--r-- | engines/kyra/kyra_v1.cpp | 10 |
2 files changed, 8 insertions, 5 deletions
diff --git a/engines/kyra/gui_lol.cpp b/engines/kyra/gui_lol.cpp index bedc1a2d39..356b08e740 100644 --- a/engines/kyra/gui_lol.cpp +++ b/engines/kyra/gui_lol.cpp @@ -905,7 +905,7 @@ void LoLEngine::gui_initMagicSubmenu(int charNum) { void LoLEngine::gui_initButton(int index, int x, int y, int val) { Button *b = new Button; - memset (b, 0, sizeof(Button)); + memset(b, 0, sizeof(Button)); int cnt = 1; @@ -919,7 +919,6 @@ void LoLEngine::gui_initButton(int index, int x, int y, int val) { } n->nextButton = b; - } else { _activeButtons = b; } diff --git a/engines/kyra/kyra_v1.cpp b/engines/kyra/kyra_v1.cpp index 4615a0a5fc..6106efdf9c 100644 --- a/engines/kyra/kyra_v1.cpp +++ b/engines/kyra/kyra_v1.cpp @@ -370,10 +370,14 @@ int KyraEngine_v1::checkInput(Button *buttonList, bool mainLoop) { } GUI *guiInstance = gui(); - if (guiInstance && keys) - return guiInstance->processButtonList(buttonList, keys | 0x8000, mouseWheel); - else + if (guiInstance) { + if (keys) + return guiInstance->processButtonList(buttonList, keys | 0x8000, mouseWheel); + else + return guiInstance->processButtonList(buttonList, 0, mouseWheel); + } else { return keys; + } } void KyraEngine_v1::updateInput() { |