X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;f=src%2Fmswin%2Ffg_main_mswin.c;h=54ec12c5cb517e397cd6f109fcbb8cb975d681ae;hb=7ce62fee66f89db514ed1b80e6c3aa287a2f8d74;hp=55280f1a095115735f66ade39b89141000423446;hpb=91cac2f34bfc430f6a68ea950cc8f5169327b794;p=freeglut diff --git a/src/mswin/fg_main_mswin.c b/src/mswin/fg_main_mswin.c index 55280f1..54ec12c 100644 --- a/src/mswin/fg_main_mswin.c +++ b/src/mswin/fg_main_mswin.c @@ -1,5 +1,5 @@ /* - * freeglut_main_mswin.c + * fg_main_mswin.c * * The Windows-specific mouse cursor related stuff. * @@ -1640,8 +1640,7 @@ void fgPlatformPosResZordWork(SFG_Window* window, unsigned int workMask) /* For fullscreen mode, find the monitor that is covered the most * by the window and get its rect as the resize target. */ - GetWindowRect(window->Window.Handle, &rect); - hMonitor= MonitorFromRect(&rect, MONITOR_DEFAULTTONEAREST); + hMonitor= MonitorFromWindow(window->Window.Handle, MONITOR_DEFAULTTONEAREST); mi.cbSize = sizeof(mi); GetMonitorInfo(hMonitor, &mi); rect = mi.rcMonitor;