Commit f76de3d0 authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard

user32: Initialize MONITORINFO.cbSize.

parent 03585070
...@@ -248,6 +248,7 @@ static HFONT MSGBOX_OnInit(HWND hwnd, LPMSGBOXPARAMSW lpmb) ...@@ -248,6 +248,7 @@ static HFONT MSGBOX_OnInit(HWND hwnd, LPMSGBOXPARAMSW lpmb)
/* Message boxes are always desktop centered, so query desktop size and center window */ /* Message boxes are always desktop centered, so query desktop size and center window */
monitor = MonitorFromWindow(lpmb->hwndOwner ? lpmb->hwndOwner : GetActiveWindow(), MONITOR_DEFAULTTOPRIMARY); monitor = MonitorFromWindow(lpmb->hwndOwner ? lpmb->hwndOwner : GetActiveWindow(), MONITOR_DEFAULTTOPRIMARY);
mon_info.cbSize = sizeof(mon_info);
GetMonitorInfoW(monitor, &mon_info); GetMonitorInfoW(monitor, &mon_info);
wleft = (mon_info.rcWork.left + mon_info.rcWork.right - wwidth) / 2; wleft = (mon_info.rcWork.left + mon_info.rcWork.right - wwidth) / 2;
wtop = (mon_info.rcWork.top + mon_info.rcWork.bottom - wheight) / 2; wtop = (mon_info.rcWork.top + mon_info.rcWork.bottom - wheight) / 2;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment