]> git.localhorst.tv Git - l2e.git/commitdiff
added inactive menu font
authorDaniel Karbach <daniel.karbach@localhorst.tv>
Tue, 27 Nov 2012 13:04:09 +0000 (14:04 +0100)
committerDaniel Karbach <daniel.karbach@localhorst.tv>
Tue, 27 Nov 2012 13:04:09 +0000 (14:04 +0100)
src/main.cpp
src/menu/EquipMenu.cpp
test-data/menu-font-inactive.png [new file with mode: 0644]

index 08547d6088a3ab529dcac49b3334d2fd1f7f0eba..d0213e7070c10dd384ebac9a2b8efcf50936bb11 100644 (file)
@@ -298,6 +298,8 @@ int main(int argc, char **argv) {
 
                graphics::Sprite menuFontSprite(IMG_Load("test-data/menu-font.png"), 16, 16);
                graphics::Font menuFont(&menuFontSprite, 0, -2);
+               graphics::Sprite menuInactiveFontSprite(IMG_Load("test-data/menu-font-inactive.png"), 16, 16);
+               graphics::Font menuInactiveFont(&menuInactiveFontSprite, 0, -2);
 
                menuResources.normalFont = &menuFont;
 
@@ -389,8 +391,7 @@ int main(int argc, char **argv) {
                inventoryMenuProperties.cursor = &menuCursor;
                inventoryMenuProperties.selectedCursor = &menuActiveCursor;
                inventoryMenuProperties.font = &menuFont;
-               // TODO: disabled font
-               inventoryMenuProperties.disabledFont = &menuFont;
+               inventoryMenuProperties.disabledFont = &menuInactiveFont;
                inventoryMenuProperties.iconSpace = 16;
                inventoryMenuProperties.charsPerNumber = 2;
                inventoryMenuProperties.delimiter = ':';
@@ -405,8 +406,7 @@ int main(int argc, char **argv) {
                spellMenuProperties.cursor = &menuCursor;
                spellMenuProperties.selectedCursor = &menuActiveCursor;
                spellMenuProperties.font = &menuFont;
-               // TODO: disabled font
-               spellMenuProperties.disabledFont = &menuFont;
+               spellMenuProperties.disabledFont = &menuInactiveFont;
                spellMenuProperties.iconSpace = 0;
                spellMenuProperties.charsPerNumber = 2;
                spellMenuProperties.delimiter = ':';
@@ -431,8 +431,6 @@ int main(int argc, char **argv) {
                equipmentMenuProperties.cursor = &menuCursor;
                equipmentMenuProperties.selectedCursor = &menuActiveCursor;
                equipmentMenuProperties.font = menuResources.statusFont;
-               // TODO: disabled font
-               equipmentMenuProperties.disabledFont = menuResources.statusFont;
                equipmentMenuProperties.iconSpace = 16;
                menuResources.equipmentMenuProperties = &equipmentMenuProperties;
 
index 199b8e1265c7069a8d169118fb8ed05a4c438276..0caff55467b5779a00f72b559d647c6e80cf16d5 100644 (file)
@@ -287,7 +287,7 @@ void EquipMenu::LoadEquipment() {
                        const Item *item(GetHero().Equipment(Hero::EquipSlot(i)));
                        equipmentMenu.Add(item->Name(), item, true, item->MenuIcon());
                } else {
-                       equipmentMenu.Add(parent->Res().noEquipmentText, 0, false);
+                       equipmentMenu.Add(parent->Res().noEquipmentText, 0);
                }
        }
 }
diff --git a/test-data/menu-font-inactive.png b/test-data/menu-font-inactive.png
new file mode 100644 (file)
index 0000000..7ffc57a
Binary files /dev/null and b/test-data/menu-font-inactive.png differ