Fixed the button states in the toolbar when loading, starting, and stopping a game.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4877 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
skidau
2010-01-18 12:10:51 +00:00
parent 896850b176
commit 335c056586
5 changed files with 107 additions and 29 deletions

View File

@ -509,8 +509,6 @@ void CFrame::OnQuit(wxCommandEvent& WXUNUSED (event))
void CFrame::OnActive(wxActivateEvent& event)
{
event.Skip();
if (event.GetActive())
UpdateGUI();
}
void CFrame::OnClose(wxCloseEvent& event)
@ -681,7 +679,9 @@ void CFrame::OnGameListCtrl_ItemActivated(wxListEvent& WXUNUSED (event))
m_GameListCtrl->Update();
}
else BootGame();
else
// Game started by double click
StartGame();
}
void CFrame::OnKeyDown(wxKeyEvent& event)
@ -795,6 +795,10 @@ void CFrame::OnMotion(wxMouseEvent& event)
#if wxUSE_TIMER
void CFrame::Update()
{
// Update the GUI while a game has not yet been loaded
if (!Core::isRunning())
UpdateGUI();
// Check if auto hide is on, or if we are already hiding the cursor all the time
if(!SConfig::GetInstance().m_LocalCoreStartupParameter.bAutoHideCursor
|| SConfig::GetInstance().m_LocalCoreStartupParameter.bHideCursor) return;