Moved a debugging check to the plugin from the main debugger. I still can't enable the sound plugin window in the Release build because I haven't figured out why calls to SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str() crashes in a Release build.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@764 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
580193658a
commit
a7fa1410c2
|
@ -282,11 +282,6 @@ void CCodeWindow::CreateGUIControls(const SCoreStartupParameter& _LocalCoreStart
|
||||||
}
|
}
|
||||||
|
|
||||||
if(IsLoggingActivated() && bSoundWindow)
|
if(IsLoggingActivated() && bSoundWindow)
|
||||||
{
|
|
||||||
if(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.find("LLE") != -1)
|
|
||||||
// no match = -1, in that case this is ignored
|
|
||||||
{
|
|
||||||
if (Core::GetState() != Core::CORE_UNINITIALIZED)
|
|
||||||
{
|
{
|
||||||
// possible todo: add some kind of if here to? can it fail?
|
// possible todo: add some kind of if here to? can it fail?
|
||||||
CPluginManager::GetInstance().OpenDebug(
|
CPluginManager::GetInstance().OpenDebug(
|
||||||
|
@ -294,15 +289,6 @@ void CCodeWindow::CreateGUIControls(const SCoreStartupParameter& _LocalCoreStart
|
||||||
SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str()
|
SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str()
|
||||||
);
|
);
|
||||||
} // don't have any else, just ignore it
|
} // don't have any else, just ignore it
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
CPluginManager::GetInstance().OpenDebug(
|
|
||||||
GetHandle(),
|
|
||||||
SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str()
|
|
||||||
);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -845,33 +831,13 @@ void CCodeWindow::OnToggleSoundWindow(wxCommandEvent& event)
|
||||||
ini.Set("ShowOnStart", "SoundWindow", show);
|
ini.Set("ShowOnStart", "SoundWindow", show);
|
||||||
ini.Save("Debugger.ini");
|
ini.Save("Debugger.ini");
|
||||||
|
|
||||||
|
|
||||||
if (IsLoggingActivated() && show)
|
if (IsLoggingActivated() && show)
|
||||||
{
|
{
|
||||||
// we only need to prevent this with the LLE, therefore this check
|
// TODO: add some kind of if() check here to?
|
||||||
if(SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.find("LLE") != -1)
|
|
||||||
// no match = -1, in that case this is ignored
|
|
||||||
{
|
|
||||||
if (Core::GetState() != Core::CORE_UNINITIALIZED)
|
|
||||||
{
|
|
||||||
// TODO: add some kind of if here to?
|
|
||||||
CPluginManager::GetInstance().OpenDebug(
|
CPluginManager::GetInstance().OpenDebug(
|
||||||
GetHandle(),
|
GetHandle(),
|
||||||
SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str()
|
SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str()
|
||||||
);
|
);
|
||||||
} else {
|
|
||||||
event.Skip();
|
|
||||||
wxMessageBox(_T("Please start the emulator before doing this."));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
CPluginManager::GetInstance().OpenDebug(
|
|
||||||
GetHandle(),
|
|
||||||
SConfig::GetInstance().m_LocalCoreStartupParameter.m_strDSPPlugin.c_str()
|
|
||||||
);
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
else // hide
|
else // hide
|
||||||
{
|
{
|
||||||
|
|
|
@ -61,6 +61,8 @@ uint32 g_LastDMASize = 0;
|
||||||
|
|
||||||
extern u32 m_addressPBs;
|
extern u32 m_addressPBs;
|
||||||
bool AXTask(u32& _uMail);
|
bool AXTask(u32& _uMail);
|
||||||
|
|
||||||
|
bool bCanWork = false;
|
||||||
// ==============
|
// ==============
|
||||||
|
|
||||||
|
|
||||||
|
@ -117,16 +119,27 @@ void DSP_DoState(unsigned char **ptr, int mode) {
|
||||||
|
|
||||||
void DllDebugger(HWND _hParent)
|
void DllDebugger(HWND _hParent)
|
||||||
{
|
{
|
||||||
#if (defined (_DEBUG) || defined (DEBUGFAST)) && defined (_WIN32)
|
#ifdef _WIN32
|
||||||
|
#if defined (_DEBUG) || defined (DEBUGFAST)
|
||||||
|
if(bCanWork)
|
||||||
|
{
|
||||||
g_Dialog.Create(NULL); //_hParent);
|
g_Dialog.Create(NULL); //_hParent);
|
||||||
g_Dialog.ShowWindow(SW_SHOW);
|
g_Dialog.ShowWindow(SW_SHOW);
|
||||||
|
|
||||||
// Open the console window
|
// Open the console window
|
||||||
startConsoleWin(155, 10000, "Sound Debugging"); // give room for 2000 rows
|
startConsoleWin(155, 100, "Sound Debugging"); // give room for 100 rows
|
||||||
wprintf("DllDebugger > Console opened\n");
|
wprintf("DllDebugger > Console opened\n");
|
||||||
// TODO: Make this adjustable from the Debugging window
|
// TODO: Make this adjustable from the Debugging window
|
||||||
MoveWindow(GetConsoleHwnd(), 0,400, 1280,500, true);
|
MoveWindow(GetConsoleHwnd(), 0,400, 1280,500, true);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
// TODO: let us open the debugging window when we open the Dolphin-Debugger, fix the crash
|
||||||
|
// that currently occurs of you try to do that
|
||||||
|
MessageBox(0, "Can't open debugging window yet. Please start a game first", "DSP LLE", 0);
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
MessageBox(0, "Can't open debugging window in Release build of this plugin.", "DSP LLE", 0);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -206,7 +219,7 @@ void dspi_req_dsp_irq()
|
||||||
|
|
||||||
void DSP_Initialize(DSPInitialize _dspInitialize)
|
void DSP_Initialize(DSPInitialize _dspInitialize)
|
||||||
{
|
{
|
||||||
bool bCanWork = true;
|
bCanWork = true;
|
||||||
g_dspInitialize = _dspInitialize;
|
g_dspInitialize = _dspInitialize;
|
||||||
|
|
||||||
gdsp_init();
|
gdsp_init();
|
||||||
|
|
Loading…
Reference in New Issue