mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-05-06 19:01:36 +03:00
Updating Cheats manager when the ISO is changed etc.
The Cheats manager should be updated when the ISO is changed because it's non-modal Removing code that read the ID from file because the cheats manager only has a use when an emulation is running (when the ID doesn't need to be read from the ISO again because it's in a variable). This fixes loading Gecko codes for .wad during an emulation because "VolumeHandler::GetVolume()" return false in this case
This commit is contained in:
parent
719f18a122
commit
7cc2e3146b
5 changed files with 57 additions and 22 deletions
|
@ -1133,6 +1133,7 @@ void CFrame::OnConfigMain(wxCommandEvent& WXUNUSED (event))
|
|||
CConfigMain ConfigMain(this);
|
||||
if (ConfigMain.ShowModal() == wxID_OK)
|
||||
m_GameListCtrl->Update();
|
||||
UpdateGUI();
|
||||
}
|
||||
|
||||
void CFrame::OnConfigGFX(wxCommandEvent& WXUNUSED (event))
|
||||
|
@ -1568,6 +1569,9 @@ void CFrame::UpdateGUI()
|
|||
if (DiscIO::CNANDContentManager::Access().GetNANDLoader(TITLEID_SYSMENU).IsValid())
|
||||
GetMenuBar()->FindItem(IDM_LOAD_WII_MENU)->Enable(!Initialized);
|
||||
|
||||
// Tools
|
||||
GetMenuBar()->FindItem(IDM_CHEATS)->Enable(SConfig::GetInstance().m_LocalCoreStartupParameter.bEnableCheats);
|
||||
|
||||
GetMenuBar()->FindItem(IDM_CONNECT_WIIMOTE1)->Enable(RunningWii);
|
||||
GetMenuBar()->FindItem(IDM_CONNECT_WIIMOTE2)->Enable(RunningWii);
|
||||
GetMenuBar()->FindItem(IDM_CONNECT_WIIMOTE3)->Enable(RunningWii);
|
||||
|
@ -1675,6 +1679,15 @@ void CFrame::UpdateGUI()
|
|||
|
||||
// Commit changes to manager
|
||||
m_Mgr->Update();
|
||||
|
||||
// Update non-modal windows
|
||||
if (g_CheatsWindow)
|
||||
{
|
||||
if (SConfig::GetInstance().m_LocalCoreStartupParameter.bEnableCheats)
|
||||
g_CheatsWindow->UpdateGUI();
|
||||
else
|
||||
g_CheatsWindow->Close();
|
||||
}
|
||||
}
|
||||
|
||||
void CFrame::UpdateGameList()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue