Some fixes to Stop() process.

Unbreak linux stop on Single Core, remove an unnecessary wait event, fix DSP HLE/DSP LLE/OGL plugin hang on stop when the config dialog has been opened (nJoy and Wiimote still need to be fixed), avoid the CpuThread to be stuck in the efb/swap loop by setting a flag before the thread is actually shutdown (contrary to r4756 which was setting it.. after :D)
Clear the status bar Framerate/Core message when the game is stopped.

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@4769 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
sl1nk3.s
2010-01-01 03:55:39 +00:00
parent 25abd0f944
commit 5877961354
8 changed files with 113 additions and 96 deletions

View File

@ -115,8 +115,12 @@ LRESULT CALLBACK WndProc( HWND hWnd, UINT iMsg, WPARAM wParam, LPARAM lParam )
case WM_CLOSE:
// When the user closes the window, we post an event to the main window to call Stop()
// Which then handles all the necessary steps to Shutdown the core + the plugins
PostMessage( m_hMain, WM_USER, WM_USER_STOP, 0 );
return 0;
if (m_hParent == NULL)
{
PostMessage( m_hMain, WM_USER, WM_USER_STOP, 0 );
return 0;
}
break;
case WM_USER:
// if (wParam == TOGGLE_FULLSCREEN)
@ -170,6 +174,7 @@ HWND OpenWindow(HWND parent, HINSTANCE hInstance, int width, int height, const T
else
{
m_hMain = parent;
m_hParent = NULL;
DWORD style = g_Config.bFullscreen ? WS_POPUP : WS_OVERLAPPEDWINDOW;
@ -208,8 +213,11 @@ HWND Create(HWND hParent, HINSTANCE hInstance, const TCHAR *title)
void Close()
{
DestroyWindow(m_hWnd);
UnregisterClass(m_szClassName, m_hInstance);
if (m_hWnd && !g_Config.RenderToMainframe)
{
DestroyWindow(m_hWnd);
UnregisterClass(m_szClassName, m_hInstance);
}
}
void SetSize(int width, int height)