fix for emu window not showing up after it gets saved at position (-32000,-32000)

This commit is contained in:
nitsuja 2009-07-29 04:51:38 +00:00
parent 146f8b43df
commit d9b6e86c40
1 changed files with 2 additions and 0 deletions

View File

@ -1545,6 +1545,8 @@ int _main()
ForceRatio = GetPrivateProfileBool("Video","Window Force Ratio", 1, IniName);
WndX = GetPrivateProfileInt("Video","WindowPosX", CW_USEDEFAULT, IniName);
WndY = GetPrivateProfileInt("Video","WindowPosY", CW_USEDEFAULT, IniName);
if(WndX < -10000) WndX = CW_USEDEFAULT; // fix for missing window problem
if(WndY < -10000) WndY = CW_USEDEFAULT; // (happens if you close desmume while it's minimized)
video.width = GetPrivateProfileInt("Video", "Width", 256, IniName);
video.height = GetPrivateProfileInt("Video", "Height", 384, IniName);