Fix to last commit

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1433 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
John Peterson
2008-12-08 01:55:43 +00:00
parent 9e0439a193
commit f5fa53a397
2 changed files with 32 additions and 30 deletions

View File

@ -196,34 +196,35 @@ bool DolphinApp::OnInit()
}
// ---------
// create debugger
// Create debugger
if (UseDebugger)
{
g_pCodeWindow = new CCodeWindow(SConfig::GetInstance().m_LocalCoreStartupParameter, main_frame);
g_pCodeWindow->Show(true);
/* If we have selected Automatic Start, start the default ISO, or if no default
ISO exists, start the last loaded ISO */
if (g_pCodeWindow->AutomaticStart())
{
if(!SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDefaultGCM.empty()
&& File::Exists(SConfig::GetInstance().m_LocalCoreStartupParameter.
m_strDefaultGCM.c_str()))
{
BootManager::BootCore(SConfig::GetInstance().m_LocalCoreStartupParameter.
m_strDefaultGCM);
}
else if(!SConfig::GetInstance().m_LastFilename.empty()
&& File::Exists(SConfig::GetInstance().m_LastFilename.c_str()))
{
BootManager::BootCore(SConfig::GetInstance().m_LastFilename);
}
}
}
// First check if we have a elf command line
if (LoadElf && ElfFile != wxEmptyString)
{
BootManager::BootCore(std::string(ElfFile.ToAscii()));
}
/* If we have selected Automatic Start, start the default ISO, or if no default
ISO exists, start the last loaded ISO */
else if (UseDebugger && g_pCodeWindow->AutomaticStart())
{
if(!SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDefaultGCM.empty()
&& File::Exists(SConfig::GetInstance().m_LocalCoreStartupParameter.
m_strDefaultGCM.c_str()))
{
BootManager::BootCore(SConfig::GetInstance().m_LocalCoreStartupParameter.
m_strDefaultGCM);
}
else if(!SConfig::GetInstance().m_LastFilename.empty()
&& File::Exists(SConfig::GetInstance().m_LastFilename.c_str()))
{
BootManager::BootCore(SConfig::GetInstance().m_LastFilename);
}
}
SetTopWindow(main_frame);
return true;