aboutsummaryrefslogtreecommitdiff
path: root/engines/kyra/gui.cpp
diff options
context:
space:
mode:
authorFlorian Kagerer2009-06-21 16:59:51 +0000
committerFlorian Kagerer2009-06-21 16:59:51 +0000
commit5b0b0051c15ff23ed8daf801d4b56cbaadf2f101 (patch)
treed31c624eeac5d269dab37a88b813fe64f410d7f2 /engines/kyra/gui.cpp
parent245a2764fca6bf4ed4798b4e68fd82e4c61bb33c (diff)
downloadscummvm-rg350-5b0b0051c15ff23ed8daf801d4b56cbaadf2f101.tar.gz
scummvm-rg350-5b0b0051c15ff23ed8daf801d4b56cbaadf2f101.tar.bz2
scummvm-rg350-5b0b0051c15ff23ed8daf801d4b56cbaadf2f101.zip
LOL: - implemented audio menu
- menu settings now get saved - remove white spaces svn-id: r41729
Diffstat (limited to 'engines/kyra/gui.cpp')
-rw-r--r--engines/kyra/gui.cpp21
1 files changed, 15 insertions, 6 deletions
diff --git a/engines/kyra/gui.cpp b/engines/kyra/gui.cpp
index c28ad68df4..85d974f675 100644
--- a/engines/kyra/gui.cpp
+++ b/engines/kyra/gui.cpp
@@ -142,12 +142,12 @@ void GUI::initMenu(Menu &menu) {
else
printMenuText(getMenuItemTitle(menu.item[i]), textX, textY, menu.item[i].textColor, 0, 8);
} else {
- printMenuText(getMenuItemTitle(menu.item[i]), textX - 1, textY + 1, defaultColor1(), 0, 0);
+ printMenuText(getMenuItemTitle(menu.item[i]), textX - 1, textY + 1, defaultColor1(), 0, 0);
if (i == menu.highlightedItem)
printMenuText(getMenuItemTitle(menu.item[i]), textX, textY, menu.item[i].highlightColor, 0, 0);
else
printMenuText(getMenuItemTitle(menu.item[i]), textX, textY, menu.item[i].textColor, 0, 0);
- }
+ }
}
}
@@ -196,6 +196,17 @@ void GUI::processHighlights(Menu &menu) {
int mouseX = p.x;
int mouseY = p.y;
+ if (_vm->_flags.gameID == GI_LOL && menu.highlightedItem != 255) {
+ // LoL doesnt't have default highlighted items.
+ // We use a highlightedItem value of 255 for this.
+
+ // With LoL no highlighting should take place unless the
+ // mouse cursor moves over a button. The highlighting should end
+ // when the mouse cursor leaves the button.
+ if (menu.item[menu.highlightedItem].enabled)
+ redrawText(menu);
+ }
+
for (int i = 0; i < menu.numberOfItems; ++i) {
if (!menu.item[i].enabled)
continue;
@@ -209,10 +220,8 @@ void GUI::processHighlights(Menu &menu) {
if (mouseX > x1 && mouseX < x2 &&
mouseY > y1 && mouseY < y2) {
- if (menu.highlightedItem != i) {
- // LoL doesnt't have default highlighted items.
- // We use a highlightedItem value of 255 for this.
- if (menu.highlightedItem != 255) {
+ if (menu.highlightedItem != i || _vm->_flags.gameID == GI_LOL) {
+ if (_vm->_flags.gameID != GI_LOL) {
if (menu.item[menu.highlightedItem].enabled)
redrawText(menu);
}