aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDavid Symonds2007-01-07 13:00:54 +0000
committerDavid Symonds2007-01-07 13:00:54 +0000
commitf1e5f0428718d9b96419dc2a24442f707170335b (patch)
tree79cee8b3c6b40f69a776abaa1b9b52004fbe15d1
parent70f323e0911cc21a6c6a5e3e1c4c2180e618b88a (diff)
downloadscummvm-rg350-f1e5f0428718d9b96419dc2a24442f707170335b.tar.gz
scummvm-rg350-f1e5f0428718d9b96419dc2a24442f707170335b.tar.bz2
scummvm-rg350-f1e5f0428718d9b96419dc2a24442f707170335b.zip
Fix interpretation of enable.item() and disable.item() AGI functions; they affect *all* menu items with the given event code. This is most relevant to menu separators which are normally disabled, and often all share the same event code.
svn-id: r25046
-rw-r--r--engines/agi/menu.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/engines/agi/menu.cpp b/engines/agi/menu.cpp
index ed2fc96dfa..fb452856db 100644
--- a/engines/agi/menu.cpp
+++ b/engines/agi/menu.cpp
@@ -440,7 +440,8 @@ void Menu::set_item(int event, int state) {
agi_menu_option *d = *iterv;
if (d->event == event) {
d->enabled = state;
- return;
+ // keep going; we need to set the state of every menu item
+ // with this event code. -- dsymonds
}
}
}