From e22ecb1585732fe7f950b72ed7021590597461ad Mon Sep 17 00:00:00 2001 From: James Ross-Gowan Date: Mon, 9 Mar 2015 22:15:01 +1100 Subject: w32_common: remove redundant is_maximized function This already exists as IsMaximized in the Windows API. (cherry picked from commit 5f0eda7b94e5af25970bfd5bef0cf401fe3a10e7) --- video/out/w32_common.c | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/video/out/w32_common.c b/video/out/w32_common.c index 4959b39bca..614d6ec8a7 100644 --- a/video/out/w32_common.c +++ b/video/out/w32_common.c @@ -312,16 +312,9 @@ static void subtract_window_borders(HWND hwnd, RECT *rc) rc->bottom -= b.bottom; } -static bool is_maximized(struct vo_w32_state *w32) -{ - WINDOWPLACEMENT wp = { .length = sizeof(WINDOWPLACEMENT) }; - GetWindowPlacement(w32->window, &wp); - return wp.showCmd == SW_SHOWMAXIMIZED; -} - static LRESULT borderless_nchittest(struct vo_w32_state *w32, int x, int y) { - if (is_maximized(w32)) + if (IsMaximized(w32->window)) return HTCLIENT; POINT mouse = { x, y }; -- cgit v1.2.3