From 57b02cac307378a168b677ed26714a876bd4aa2b Mon Sep 17 00:00:00 2001 From: fledge68 Date: Wed, 14 Aug 2013 16:11:26 +0000 Subject: [PATCH] - Fixes for user labels on wbfs menu and wad menu and nand settings menu and added to boot (startup) menu --- source/menu/menu.cpp | 4 ++-- source/menu/menu_boot.cpp | 8 ++++++++ source/menu/menu_nandemu.cpp | 12 +++++++++--- 3 files changed, 19 insertions(+), 5 deletions(-) diff --git a/source/menu/menu.cpp b/source/menu/menu.cpp index d7bae0ad..f4a4743f 100644 --- a/source/menu/menu.cpp +++ b/source/menu/menu.cpp @@ -1133,6 +1133,8 @@ void CMenu::_buildMenus(void) // Build menus _initMainMenu(); _initErrorMenu(); + _initWad(); + _initWBFSMenu(); _initConfigAdvMenu(); _initConfigSndMenu(); _initConfig4Menu(); @@ -1143,7 +1145,6 @@ void CMenu::_buildMenus(void) _initDownloadMenu(); _initCodeMenu(); _initAboutMenu(); - _initWBFSMenu(); _initCFThemeMenu(); _initGameSettingsMenu(); _initCheatSettingsMenu(); @@ -1158,7 +1159,6 @@ void CMenu::_buildMenus(void) _initCoverBanner(); _initExplorer(); _initBoot(); - _initWad(); _loadCFCfg(); } diff --git a/source/menu/menu_boot.cpp b/source/menu/menu_boot.cpp index 31f2b849..358b7d8f 100644 --- a/source/menu/menu_boot.cpp +++ b/source/menu/menu_boot.cpp @@ -31,6 +31,7 @@ s16 m_bootLblUSBPort; s16 m_bootBtnUSBPort; s16 m_bootBtnBack; +s16 m_bootLblUser[4]; u8 set_port = 0; @@ -49,6 +50,9 @@ static void showBoot(void) m_btnMgr.show(m_bootBtnUSBPort); m_btnMgr.show(m_bootBtnBack); + for(u8 i = 0; i < ARRAY_SIZE(m_bootLblUser); ++i) + if(m_bootLblUser[i] != -1) + m_btnMgr.show(m_bootLblUser[i]); } static void hideBoot(bool instant) @@ -66,6 +70,9 @@ static void hideBoot(bool instant) m_btnMgr.hide(m_bootBtnUSBPort, instant); m_btnMgr.hide(m_bootBtnBack, instant); + for(u8 i = 0; i < ARRAY_SIZE(m_bootLblUser); ++i) + if(m_bootLblUser[i] != -1) + m_btnMgr.hide(m_bootLblUser[i], instant); } bool CMenu::_Boot(void) @@ -154,6 +161,7 @@ void CMenu::_textBoot(void) void CMenu::_initBoot(void) { + _addUserLabels(m_bootLblUser, ARRAY_SIZE(m_bootLblUser), "BOOT"); m_bootLblTitle = _addTitle("BOOT/TITLE", theme.titleFont, L"", 20, 30, 600, 60, theme.titleFontColor, FTGX_JUSTIFY_CENTER | FTGX_ALIGN_MIDDLE); m_bootLblLoadCIOS = _addLabel("BOOT/LOAD_CIOS", theme.lblFont, L"", 40, 130, 290, 56, theme.lblFontColor, FTGX_JUSTIFY_LEFT | FTGX_ALIGN_MIDDLE); diff --git a/source/menu/menu_nandemu.cpp b/source/menu/menu_nandemu.cpp index c99a83c7..9ed4a1a2 100644 --- a/source/menu/menu_nandemu.cpp +++ b/source/menu/menu_nandemu.cpp @@ -212,7 +212,10 @@ void CMenu::_hideNandEmu(bool instant) m_btnMgr.hide(m_nandemuBtnExtract, instant); m_btnMgr.hide(m_nandemuBtnPartition, instant); m_btnMgr.hide(m_nandemuBtnDisable, instant); - m_btnMgr.hide(m_nandemuLblInit, instant); + m_btnMgr.hide(m_nandemuLblInit, instant); + for(u8 i = 0; i < ARRAY_SIZE(m_nandemuLblUser); ++i) + if(m_nandemuLblUser[i] != -1) + m_btnMgr.hide(m_nandemuLblUser[i], instant); } void CMenu::_showNandEmu(void) @@ -230,7 +233,7 @@ void CMenu::_showNandEmu(void) if(nandemuPage == 1) { int i; - if(((m_current_view == COVERFLOW_CHANNEL && !m_cfg.getBool(CHANNEL_DOMAIN, "disable", true)) || m_current_view == COVERFLOW_USB) && !m_locked) + if(((m_current_view == COVERFLOW_CHANNEL && !m_cfg.getBool(CHANNEL_DOMAIN, "disable", true)) || m_current_view == COVERFLOW_USB)) { m_btnMgr.show(m_nandemuLblEmulation); m_btnMgr.show(m_nandemuLblEmulationVal); @@ -238,7 +241,7 @@ void CMenu::_showNandEmu(void) m_btnMgr.show(m_nandemuBtnEmulationM); } - if((m_current_view == COVERFLOW_CHANNEL || m_current_view == COVERFLOW_USB) && !m_locked) + if((m_current_view == COVERFLOW_CHANNEL || m_current_view == COVERFLOW_USB)) { m_btnMgr.show(m_nandemuLblSaveDump); m_btnMgr.show(m_nandemuBtnAll); @@ -264,6 +267,9 @@ void CMenu::_showNandEmu(void) m_btnMgr.show(m_nandemuLblNandSavesFolder); m_btnMgr.show(m_nandemuBtnNandSavesFolder); } + for(u8 i = 0; i < ARRAY_SIZE(m_nandemuLblUser); ++i) + if(m_nandemuLblUser[i] != -1) + m_btnMgr.show(m_nandemuLblUser[i]); } int CMenu::_NandEmuCfg(void)