From 013c024b2b1247727e20c83a2e0f190728c80df5 Mon Sep 17 00:00:00 2001 From: Zebediah Figura Date: Thu, 7 May 2020 20:50:22 -0500 Subject: [PATCH] quartz: Get rid of the resize callback. Signed-off-by: Zebediah Figura Signed-off-by: Alexandre Julliard --- dlls/quartz/quartz_private.h | 4 ---- dlls/quartz/videorenderer.c | 11 ----------- dlls/quartz/vmr9.c | 11 ----------- dlls/quartz/window.c | 4 ++-- 4 files changed, 2 insertions(+), 28 deletions(-) diff --git a/dlls/quartz/quartz_private.h b/dlls/quartz/quartz_private.h index d3f3a8915ae..33cfb5671f5 100644 --- a/dlls/quartz/quartz_private.h +++ b/dlls/quartz/quartz_private.h @@ -106,11 +106,7 @@ struct video_window struct video_window_ops { - /* Required */ RECT (*get_default_rect)(struct video_window *window); - /* Optional, WinProc Related */ - BOOL (*resize)(struct video_window *window, LONG height, LONG width); - HRESULT (*get_current_image)(struct video_window *window, LONG *size, LONG *image); }; diff --git a/dlls/quartz/videorenderer.c b/dlls/quartz/videorenderer.c index 8504a51d747..e004d0fc214 100644 --- a/dlls/quartz/videorenderer.c +++ b/dlls/quartz/videorenderer.c @@ -245,16 +245,6 @@ static RECT video_renderer_get_default_rect(struct video_window *iface) return defRect; } -static BOOL video_renderer_resize(struct video_window *iface, LONG Width, LONG Height) -{ - struct video_renderer *filter = impl_from_video_window(iface); - - TRACE("WM_SIZE %d %d\n", Width, Height); - GetClientRect(iface->hwnd, &filter->window.dst); - - return TRUE; -} - static const struct strmbase_renderer_ops renderer_ops = { .pfnCheckMediaType = VideoRenderer_CheckMediaType, @@ -317,7 +307,6 @@ static HRESULT video_renderer_get_current_image(struct video_window *iface, LONG static const struct video_window_ops window_ops = { .get_default_rect = video_renderer_get_default_rect, - .resize = video_renderer_resize, .get_current_image = video_renderer_get_current_image, }; diff --git a/dlls/quartz/vmr9.c b/dlls/quartz/vmr9.c index 64ef4a53e3e..758ede61554 100644 --- a/dlls/quartz/vmr9.c +++ b/dlls/quartz/vmr9.c @@ -663,16 +663,6 @@ static RECT vmr_get_default_rect(struct video_window *This) return defRect; } -static BOOL vmr_resize(struct video_window *This, LONG Width, LONG Height) -{ - struct quartz_vmr *pVMR9 = impl_from_video_window(This); - - TRACE("WM_SIZE %d %d\n", Width, Height); - GetClientRect(This->hwnd, &pVMR9->window.dst); - - return TRUE; -} - static HRESULT vmr_get_current_image(struct video_window *iface, LONG *size, LONG *image) { struct quartz_vmr *filter = impl_from_video_window(iface); @@ -737,7 +727,6 @@ out: static const struct video_window_ops window_ops = { .get_default_rect = vmr_get_default_rect, - .resize = vmr_resize, .get_current_image = vmr_get_current_image, }; diff --git a/dlls/quartz/window.c b/dlls/quartz/window.c index d383370e5d8..ada6b99ddb6 100644 --- a/dlls/quartz/window.c +++ b/dlls/quartz/window.c @@ -68,8 +68,8 @@ static LRESULT CALLBACK WndProcW(HWND hwnd, UINT message, WPARAM wparam, LPARAM } break; case WM_SIZE: - if (window->ops->resize) - return window->ops->resize(window, LOWORD(lparam), HIWORD(lparam)); + GetClientRect(window->hwnd, &window->dst); + break; } return DefWindowProcW(hwnd, message, wparam, lparam);