Do not BootGame if there are no items in the GameListCtrl, fix test to see if cancel was chosen from File > Open.

Fixes issue 1046.
it does leak 10kB every time that GetSelectedISO is called, I am not too worried about this. The other ways of accomplishing this would be more complicated, for little gain. Feel free to revert everything except line 466 of FrameTools.cpp :P

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3625 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
LPFaint99 2009-07-01 04:55:53 +00:00
commit 52e424485f
3 changed files with 8 additions and 7 deletions

View file

@ -508,8 +508,8 @@ void CFrame::OnGameListCtrl_ItemActivated(wxListEvent& WXUNUSED (event))
// 2. All Regions are set to hide
// Otherwise call BootGame to either...
// 1. Boot the selected iso
// 2. Call BrowseForDirectory and boot the default or last loaded iso.
// TODO: (LPFaint99) We shouldn't boot an iso after BrowseForDirectory
// 2. Boot the default or last loaded iso.
// 3. Call BrowseForDirectory if the gamelist is empty
if (!m_GameListCtrl->GetGameNames().size() &&
!((SConfig::GetInstance().m_ListGC ||
SConfig::GetInstance().m_ListWii ||