Fix an issue when a wiimote source is changed to a real wiimote in the wiimote config dialog while a game is running, and the wiimote was disconnected from the CPU. Only change the connection status when the dialog is closed.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@7229 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
Glenn Rice 2011-02-23 03:06:16 +00:00
commit ceb03781dc
3 changed files with 50 additions and 13 deletions

View file

@ -105,9 +105,10 @@ void CFrame::ToggleLogConfigWindow(bool bShow)
{
if (!m_LogConfigWindow)
m_LogConfigWindow = new LogConfigWindow(this, m_LogWindow, IDM_LOGCONFIGWINDOW);
const int nbIndex = IDM_LOGCONFIGWINDOW - IDM_LOGWINDOW;
DoAddPage(m_LogConfigWindow,
g_pCodeWindow ? g_pCodeWindow->iNbAffiliation[1] : 0,
g_pCodeWindow ? bFloatWindow[1] : false);
g_pCodeWindow ? g_pCodeWindow->iNbAffiliation[nbIndex] : 0,
g_pCodeWindow ? bFloatWindow[nbIndex] : false);
}
else
{
@ -147,9 +148,10 @@ void CFrame::ToggleConsole(bool bShow)
ConsoleWin->Reparent(ConsoleParent);
ConsoleParent->Enable();
const int nbIndex = IDM_CONSOLEWINDOW - IDM_LOGWINDOW;
DoAddPage(ConsoleParent,
g_pCodeWindow ? g_pCodeWindow->iNbAffiliation[1] : 0,
g_pCodeWindow ? bFloatWindow[1] : false);
g_pCodeWindow ? g_pCodeWindow->iNbAffiliation[nbIndex] : 0,
g_pCodeWindow ? bFloatWindow[nbIndex] : false);
}
else // Hide
{