From: Zebediah Figura zfigura@codeweavers.com
Ferro CCTV calls this. --- dlls/quartz/tests/videorenderer.c | 3 +++ dlls/quartz/tests/vmr7.c | 3 +++ dlls/quartz/tests/vmr9.c | 3 +++ dlls/quartz/window.c | 9 ++++++--- 4 files changed, 15 insertions(+), 3 deletions(-)
diff --git a/dlls/quartz/tests/videorenderer.c b/dlls/quartz/tests/videorenderer.c index f386d0e3edf..7771c467a13 100644 --- a/dlls/quartz/tests/videorenderer.c +++ b/dlls/quartz/tests/videorenderer.c @@ -2393,6 +2393,9 @@ static void test_video_window(void) hr = IVideoWindow_get_AutoShow(window, &l); todo_wine ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
+ hr = IVideoWindow_put_AutoShow(window, OAFALSE); + ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr); + testfilter_init(&source); IFilterGraph2_AddFilter(graph, &source.filter.IBaseFilter_iface, NULL); IFilterGraph2_AddFilter(graph, filter, NULL); diff --git a/dlls/quartz/tests/vmr7.c b/dlls/quartz/tests/vmr7.c index 7240e51b1d9..cbab6eb077d 100644 --- a/dlls/quartz/tests/vmr7.c +++ b/dlls/quartz/tests/vmr7.c @@ -2392,6 +2392,9 @@ static void test_video_window(void) hr = IVideoWindow_get_AutoShow(window, &l); todo_wine ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
+ hr = IVideoWindow_put_AutoShow(window, OAFALSE); + ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr); + testfilter_init(&source); IFilterGraph2_AddFilter(graph, &source.filter.IBaseFilter_iface, NULL); IFilterGraph2_AddFilter(graph, filter, NULL); diff --git a/dlls/quartz/tests/vmr9.c b/dlls/quartz/tests/vmr9.c index 8249857ff60..9c5ec2129a3 100644 --- a/dlls/quartz/tests/vmr9.c +++ b/dlls/quartz/tests/vmr9.c @@ -2618,6 +2618,9 @@ static void test_video_window(void) hr = IVideoWindow_get_AutoShow(window, &l); todo_wine ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr);
+ hr = IVideoWindow_put_AutoShow(window, OAFALSE); + ok(hr == VFW_E_NOT_CONNECTED, "Got hr %#lx.\n", hr); + testfilter_init(&source); IFilterGraph2_AddFilter(graph, &source.filter.IBaseFilter_iface, NULL); IFilterGraph2_AddFilter(graph, filter, NULL); diff --git a/dlls/quartz/window.c b/dlls/quartz/window.c index f7242ecff58..617d45b74e0 100644 --- a/dlls/quartz/window.c +++ b/dlls/quartz/window.c @@ -273,11 +273,14 @@ HRESULT WINAPI BaseControlWindowImpl_get_WindowStyleEx(IVideoWindow *iface, LONG
HRESULT WINAPI BaseControlWindowImpl_put_AutoShow(IVideoWindow *iface, LONG AutoShow) { - struct video_window *This = impl_from_IVideoWindow(iface); + struct video_window *window = impl_from_IVideoWindow(iface); + + TRACE("window %p, AutoShow %ld.\n", window, AutoShow);
- TRACE("window %p, AutoShow %ld.\n", This, AutoShow); + if (!window->pPin->peer) + return VFW_E_NOT_CONNECTED;
- This->AutoShow = AutoShow; + window->AutoShow = AutoShow;
return S_OK; }