forums.PPSSPP.org
Release Device Context Failed if I use File=>Exit - Printable Version

+- forums.PPSSPP.org (https://forums.ppsspp.org)
+-- Forum: PPSSPP - Playstation Portable Simulator Suitable for Playing Portably (/forumdisplay.php?fid=1)
+--- Forum: Development (/forumdisplay.php?fid=3)
+--- Thread: Release Device Context Failed if I use File=>Exit (/showthread.php?tid=5594)



Release Device Context Failed if I use File=>Exit - vsub_ - 08-18-2013 08:33 AM

Does this happen on anyone else.
When I use File=>Exit,I will always get a msgbox with "Release Device Context Failed" in it.

I don't get that msgbox only when I close the window by using the X button(upper right)...it's still appear but so rarely that you could say that it never appear.

It happens on all revs I tried and it doesn't matter if you start a game or not


RE: Release Device Context Failed if I use File=>Exit - bonquacks - 08-18-2013 09:23 AM

Not happening to me here on my rig in sig.

Tested with all recent revs with Windows XP.

Used the following exit methods:-

1. File --> Exit.
2. Old UI Exit button
3. New UI Exit button
4. Alt-F4
5. X Button on the top right hand corner of the window
6. Ctrl-Shift-Escape and terminate application from the Task manager.

None of them produce the issue for me.


RE: Release Device Context Failed if I use File=>Exit - vnctdj - 08-18-2013 09:30 AM

I also tested and I have no problem ! Wink


RE: Release Device Context Failed if I use File=>Exit - vsub_ - 08-18-2013 09:52 AM

Hmm,the Exit screen button and the X button are sending WM_CLOSE which is the normal way to close a window.
Code:
PostMessage(MainWindow::hwndMain, WM_CLOSE, 0, 0);
https://github.com/hrydgard/ppsspp/blob/master/UI/MenuScreens.cpp
but File=>Exit is sending WM_DESTROY
Code:
case ID_FILE_EXIT:
DestroyWindow(hWnd);
break;
https://github.com/hrydgard/ppsspp/blob/master/Windows/WndMainWindow.cpp
http://msdn.microsoft.com/en-us/library/windows/desktop/ms632682(v=vs.85).aspx