- removed m_source_cnt. its not used anymore.

This commit is contained in:
Fledge68 2022-12-10 15:36:19 -06:00
parent a2c02143f5
commit d5bfdedb19
7 changed files with 40 additions and 68 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.4 MiB

After

Width:  |  Height:  |  Size: 4.4 MiB

View File

@ -2212,7 +2212,7 @@ void CMenu::_initCF(void)
}
/*********************** sort coverflow list ***********************/
CoverFlow.setSorting(m_source_cnt > 1 ? (Sorting)0 : (Sorting)m_cfg.getInt(_domainFromView(), "sort", 0));
CoverFlow.setSorting((Sorting)m_cfg.getInt(_domainFromView(), "sort", 0));
/*********************** set box mode and small box mode **************************/
if(!m_sourceflow)
@ -2336,8 +2336,8 @@ void CMenu::_initCF(void)
}
else if(m_sourceflow && sm_numbers.size() > 0)
sourceNumber = stoi(sm_numbers[sm_numbers.size() - 1]);
else if(m_current_view == COVERFLOW_HOMEBREW || (m_source_cnt > 1 && NoGameID(m_cfg.getInt("MULTI", "current_item_type", TYPE_PLUGIN))))
filename = m_cfg.getString(_domainFromView(), "current_item", "");
else if(m_current_view == COVERFLOW_HOMEBREW)
filename = m_cfg.getString(HOMEBREW_DOMAIN, "current_item", "");
else
ID = m_cfg.getString(_domainFromView(), "current_item", "");
@ -2765,8 +2765,6 @@ const char *CMenu::_domainFromView()
{
if(m_sourceflow)
return SOURCEFLOW_DOMAIN;
if(m_source_cnt > 1)
return "MULTI";
switch(m_current_view)
{
case COVERFLOW_CHANNEL:

View File

@ -63,7 +63,6 @@ public: // functions called from outside CMenu
private:
u8 m_prev_view;
u8 m_current_view;
u8 m_source_cnt;
u8 enabledPluginsCount;
u8 m_catStartPage;
u8 m_max_categories;

View File

@ -65,8 +65,6 @@ void CMenu::_setCurrentItem(const dir_discHdr *hdr)
else
{
m_cfg.setString(_domainFromView(), "current_item", fn_id);
if(m_source_cnt > 1)
m_cfg.setInt("MULTI", "current_item_type", hdr->type);
}
}

View File

@ -149,13 +149,6 @@ void CMenu::_showCF(bool refreshList)
if(m_gameList.empty())
{
cacheCovers = false;
if(m_source_cnt > 1)
{
Msg = _t("main1", L"Game list empty!");
Pth = "";
}
else
{
switch(m_current_view)
{
case COVERFLOW_WII:
@ -196,7 +189,6 @@ void CMenu::_showCF(bool refreshList)
}
break;
}
}
Msg.append(wstringEx(' ' + Pth));
m_btnMgr.setText(m_mainLblMessage, Msg);
m_btnMgr.show(m_mainLblMessage);
@ -373,17 +365,6 @@ int CMenu::main(void)
m_prev_view = 0;
m_current_view = m_cfg.getUInt("GENERAL", "sources", COVERFLOW_WII);
m_source_cnt = 0;
for(u8 i = 1; i < 32; i <<= 1)
if(m_current_view & i)
m_source_cnt++;
if(m_source_cnt == 0)
{
m_current_view = COVERFLOW_WII;
m_cfg.setUInt("GENERAL", "sources", m_current_view);
m_source_cnt++;
}
m_catStartPage = m_cfg.getInt("GENERAL", "cat_startpage", 1);
@ -527,7 +508,7 @@ int CMenu::main(void)
m_current_view = show_plugin ? COVERFLOW_PLUGIN : (show_homebrew ? COVERFLOW_HOMEBREW : COVERFLOW_WII);
else if(m_current_view == COVERFLOW_PLUGIN)
m_current_view = show_homebrew ? COVERFLOW_HOMEBREW : COVERFLOW_WII;
else if(m_current_view == COVERFLOW_HOMEBREW || m_source_cnt > 1)
else if(m_current_view == COVERFLOW_HOMEBREW)
m_current_view = COVERFLOW_WII;
if(m_use_source)
{
@ -535,7 +516,6 @@ int CMenu::main(void)
sm_tiers_backup = SOURCE_FILENAME;
_restoreSrcTiers();
}
m_source_cnt = 1;
m_cfg.setUInt("GENERAL", "sources", m_current_view);
m_catStartPage = 1;
_getCustomBgTex();

View File

@ -184,7 +184,6 @@ void CMenu::_PluginSettings()
if(m_refreshGameList && enabledPluginsCount > 0)
{
m_cfg.setUInt("GENERAL", "sources", m_current_view);
m_source_cnt = 1;
m_catStartPage = 1;
m_cfg.setInt(CHANNEL_DOMAIN, "channels_type", channels_type);
}

View File

@ -137,7 +137,6 @@ void CMenu::_sourceFlow()
m_current_view = COVERFLOW_WII;
m_sourceflow = false;
m_cfg.setUInt("GENERAL", "sources", m_current_view);
m_source_cnt = 1;
_setSrcOptions();
}
@ -608,7 +607,6 @@ bool CMenu::_Source()
numbers.append(',' + sm_numbers[i]);
m_cfg.setString(SOURCEFLOW_DOMAIN, "numbers", numbers);
m_cfg.setUInt("GENERAL", "sources", m_current_view);
m_source_cnt = 1;
newSource = true;
break;
}