diff options
author | Eugene Sandulenko | 2016-01-18 22:05:46 +0100 |
---|---|---|
committer | Eugene Sandulenko | 2016-02-14 17:12:47 +0100 |
commit | ee8999241e115b4f38c8481ed8257176ced0dbc2 (patch) | |
tree | 022f945f87ff6ab9ba9cd9d65f1753f828c5bd1d | |
parent | 40eb91da3ce5d3bd96f749ebc749238d364cc15d (diff) | |
download | scummvm-rg350-ee8999241e115b4f38c8481ed8257176ced0dbc2.tar.gz scummvm-rg350-ee8999241e115b4f38c8481ed8257176ced0dbc2.tar.bz2 scummvm-rg350-ee8999241e115b4f38c8481ed8257176ced0dbc2.zip |
WAGE: Fix submenu rendering
-rw-r--r-- | engines/wage/gui.cpp | 4 | ||||
-rw-r--r-- | engines/wage/gui.h | 3 | ||||
-rw-r--r-- | engines/wage/menu.cpp | 8 |
3 files changed, 9 insertions, 6 deletions
diff --git a/engines/wage/gui.cpp b/engines/wage/gui.cpp index 0c83852a00..a5e9018cf4 100644 --- a/engines/wage/gui.cpp +++ b/engines/wage/gui.cpp @@ -68,8 +68,9 @@ static const byte palette[] = { }; static byte fillPattern[8] = { 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff }; -static byte fillPatternStripes[8] = { 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa, 0xaa }; +static byte fillPatternStripes[8] = { 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55, 0x55 }; static byte fillPatternCheckers[8] = { 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55 }; +static byte fillPatternCheckers2[8] = { 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa, 0x55, 0xaa }; static const byte macCursorArrow[] = { 2, 2, 3, 3, 3, 3, 3, 3, 3, 3, 3, @@ -163,6 +164,7 @@ Gui::Gui(WageEngine *engine) { _patterns.push_back(fillPattern); _patterns.push_back(fillPatternStripes); _patterns.push_back(fillPatternCheckers); + _patterns.push_back(fillPatternCheckers2); loadFonts(); diff --git a/engines/wage/gui.h b/engines/wage/gui.h index 4494771466..3f5a824a32 100644 --- a/engines/wage/gui.h +++ b/engines/wage/gui.h @@ -80,7 +80,8 @@ enum { enum { kPatternSolid = 1, kPatternStripes = 2, - kPatternCheckers = 3 + kPatternCheckers = 3, + kPatternCheckers2 = 4 }; class Gui { diff --git a/engines/wage/menu.cpp b/engines/wage/menu.cpp index b5066acd10..0577ad566e 100644 --- a/engines/wage/menu.cpp +++ b/engines/wage/menu.cpp @@ -107,9 +107,9 @@ struct MenuData { { 1, "New", kMenuActionNew, 0, false }, { 1, "Open...", kMenuActionOpen, 0, false }, { 1, "Close", kMenuActionClose, 0, true }, - { 1, "Save", kMenuActionSave, 0, true }, + { 1, "Save", kMenuActionSave, 0, false }, { 1, "Save as...", kMenuActionSaveAs, 0, true }, - { 1, "Revert", kMenuActionRevert, 0, true }, + { 1, "Revert", kMenuActionRevert, 0, false }, { 1, "Quit", kMenuActionQuit, 0, true }, { 2, "Undo", kMenuActionUndo, 'Z', false }, @@ -428,7 +428,7 @@ void Menu::renderSubmenu(MenuItem *menu) { for (int ii = 0; ii < _tempSurface.h; ii++) { const byte *src = (const byte *)_tempSurface.getBasePtr(0, ii); byte *dst = (byte *)_gui->_screen.getBasePtr(x, y+ii); - byte pat = _gui->_patterns[kPatternCheckers - 1][ii % 8]; + byte pat = _gui->_patterns[kPatternCheckers2 - 1][ii % 8]; for (int j = 0; j < r->width(); j++) { if (*src != kColorGreen && (pat & (1 << (7 - (x + j) % 8)))) *dst = *src; @@ -438,7 +438,7 @@ void Menu::renderSubmenu(MenuItem *menu) { } } } else { // Delimiter - Design::drawHLine(&_gui->_screen, r->left, r->right, y + kMenuDropdownItemHeight / 2, 1, kColorBlack, _gui->_patterns, kPatternStripes); + Design::drawHLine(&_gui->_screen, r->left + 1, r->right - 1, y + kMenuDropdownItemHeight / 2, 1, kColorBlack, _gui->_patterns, kPatternStripes); } y += kMenuDropdownItemHeight; |