- fixed the Source Menu page button when hiding buttons. the count was off by one so sometimes the page button said there was another page when there really wasn't.

- fixed a minor issue when changing a plugins rom dir but then exiting the source menu via B button without selecting a source, it wouldn't reload the current coverflow but now it does.
- now when you have only the front cover image wiiflow will use that platform's custom blank cover image for the spine and back of the cover.
- made source menu setup menu's more noticable when you switch from select a source to selecting a plugin and back. before it was hard to tell you had moved to a new menu cause they look nearly identical.
This commit is contained in:
Fledge68 2020-09-25 06:19:03 -05:00
parent ef59eccaca
commit 1595356f59
7 changed files with 69 additions and 5 deletions

Binary file not shown.

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.1 MiB

After

Width:  |  Height:  |  Size: 4.1 MiB

View File

@ -1,6 +1,6 @@
#define APP_NAME "WiiFlow WFL"
#define APP_VERSION "5.4.7 beta 5"
#define APP_VERSION "5.4.7 beta 6"
#define APP_DATA_DIR "wiiflow"
#define APPS_DIR "apps/wiiflow"

View File

@ -1974,7 +1974,7 @@ bool CCoverFlow::start(const string &m_imgsDir)
if(TexHandle.fromImageFile(m_flatNoCoverTexture, fmt("%s/flatnopic.png", m_imgsDir.c_str()), GX_TF_CMPR, 32, 512) != TE_OK)
return false;
}
m_defcovers_loaded = true;
m_defcovers_loaded = false;
}
/* allocate enough memory for the covers list (m_covers) based on rows * columns (m_range) */

View File

@ -630,11 +630,13 @@ void CMenu::_loadCFCfg()
);
// Textures
/*
string texLoading = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString(domain, "loading_cover_box").c_str());
string texNoCover = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString(domain, "missing_cover_box").c_str());
string texLoadingFlat = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString(domain, "loading_cover_flat").c_str());
string texNoCoverFlat = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString(domain, "missing_cover_flat").c_str());
CoverFlow.setTextures(texLoading, texLoadingFlat, texNoCover, texNoCoverFlat);
*/
// Font
CoverFlow.setFont(_font(domain, "font", theme.titleFont), m_theme.getColor(domain, "font_color", CColor(0xFFFFFFFF)));
}
@ -2001,6 +2003,48 @@ void CMenu::_initCF(void)
char id[74];
char catID[64];
// Set loading and no cover textures
// Set box no cover to custom blank cover to use for spine and back of cover if only front image available
string texLoading = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString("_COVERFLOW", "loading_cover_box").c_str());
string texLoadingFlat = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString("_COVERFLOW", "loading_cover_flat").c_str());
string texNoCoverFlat = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString("_COVERFLOW", "missing_cover_flat").c_str());
string texNoCover = fmt("%s/%s", m_themeDataDir.c_str(), m_theme.getString("_COVERFLOW", "missing_cover_box").c_str());
string temp;
if(m_source_cnt == 1 && m_platform.loaded())
{
if(m_current_view == COVERFLOW_PLUGIN)
{
u8 i = 0;
string name;
while(m_plugin.PluginExist(i) && !m_plugin.GetEnabledStatus(i)){ ++i; }
if(m_plugin.PluginExist(i))
name = m_platform.getString("PLUGINS", sfmt("%08x", m_plugin.GetPluginMagic(i)), "");
if(!name.empty())
{
bool match = true;
i++;
while(m_plugin.PluginExist(i))
{
if(m_plugin.GetEnabledStatus(i) && name != m_platform.getString("PLUGINS", sfmt("%08x", m_plugin.GetPluginMagic(i)), ""))
{
match = false;
break;
}
i++;
}
/* if all match we use that blank cover image */
if(match)
temp = getBlankCoverPath(&m_gameList[0]);
}
}
else
temp = getBlankCoverPath(&m_gameList[0]);
if(!temp.empty() && fsop_FileExist(temp.c_str()))
texNoCover = temp;
}
CoverFlow.setTextures(texLoading, texLoadingFlat, texNoCover, texNoCoverFlat);
// filter list based on categories and favorites
for(vector<dir_discHdr>::iterator hdr = m_gameList.begin(); hdr != m_gameList.end(); ++hdr)
{
requiredCats = m_cat.getString("GENERAL", "required_categories", "");

View File

@ -170,13 +170,20 @@ void CMenu::_checkboxesMenu(u8 md)
{
if(mode == 4)
{
m_btnMgr.setText(m_checkboxesLblTitle, _t("smedit2", L"Choose Source"));
mode = 2;
max_checkbox = m_max_source_btn;
CB_curPage = (curSource + 1) / 10 + 1;
CB_numPages = (max_checkbox / 10) + 1;
m_btnMgr.hide(m_checkboxesLblTitle, true);
for(int i = 0; i < 11; ++i)
{
m_btnMgr.hide(m_checkboxBtn[i], true);
m_btnMgr.hide(m_checkboxLblTxt[i], true);
}
_updateCheckboxes();
_updateCheckboxesText();
m_btnMgr.setText(m_checkboxesLblTitle, _t("smedit2", L"Choose Source"));
m_btnMgr.show(m_checkboxesLblTitle);
}
else
break;
@ -238,9 +245,16 @@ void CMenu::_checkboxesMenu(u8 md)
while(m_plugin.PluginExist(max_checkbox)) max_checkbox++;
CB_curPage = 1;
CB_numPages = (max_checkbox / 10) + 1;
m_btnMgr.hide(m_checkboxesLblTitle, true);
for(int i = 0; i < 11; ++i)
{
m_btnMgr.hide(m_checkboxBtn[i], true);
m_btnMgr.hide(m_checkboxLblTxt[i], true);
}
_updateCheckboxes();
_updateCheckboxesText();
m_btnMgr.setText(m_checkboxesLblTitle, _t("smedit4", L"Choose Plugins"));
m_btnMgr.show(m_checkboxesLblTitle);
}
}
else if(mode == 4)
@ -335,6 +349,7 @@ void CMenu::_checkboxesMenu(u8 md)
m_plugin_cfg.save(true);
string cachedListFile(fmt("%s/%s_%s.db", m_listCacheDir.c_str(), DeviceName[romsPartition], m_plugin.PluginMagicWord));
fsop_deleteFile(cachedListFile.c_str());
m_refreshGameList = true;
}
}
}

View File

@ -235,7 +235,7 @@ void CMenu::_srcTierLoad(string fn)
break;
}
}
numPages = (nonHiddenSources.size() / 12) + 1;
numPages = ((nonHiddenSources.size() - 1) / 12) + 1;
}
}
@ -394,6 +394,11 @@ bool CMenu::_Source()
{
_hideSource();
_SM_Editor();
if(m_refreshGameList)// if romdir changed
{
m_refreshGameList = false;
newSource = true;// in case no source is selected and they return via B button
}
nonHiddenSources.clear();
for(i = 0; i <= m_max_source_btn; i++)
{
@ -410,7 +415,7 @@ bool CMenu::_Source()
break;
}
}
numPages = (nonHiddenSources.size() / 12) + 1;
numPages = ((nonHiddenSources.size() - 1) / 12) + 1;
_showSource();
_updateSourceBtns();
}