Gabriel Ivăncescu gabrielopcode@gmail.com wrote:
/* The WM_DESTROY notification is not sent to the owner, even if the style is off */
hr = IFilterGraph2_QueryInterface(graph, &IID_IVideoWindow, (void**)&videownd);
ok(hr == S_OK, "Got hr %#x.\n", hr);
hr = IVideoWindow_put_Owner(videownd, (OAHWND)parent);
ok(hr == S_OK, "Got hr %#x.\n", hr);
IVideoWindow_Release(videownd);
} else skip("Could not find renderer window.\n");ok(!(GetWindowLongW(hwnd, GWL_EXSTYLE) & WS_EX_NOPARENTNOTIFY), "Window has WS_EX_NOPARENTNOTIFY.\n");
@@ -4285,6 +4324,9 @@ static void test_window_threading(void) ok(!ref, "Got outstanding refcount %d.\n", ref); ret = DeleteFileW(filename); ok(ret, "Failed to delete file, error %u.\n", GetLastError());
- DestroyWindow(parent);
- UnregisterClassA("TestParent", cls.hInstance);
}
It would be also helpful to test if the window gets subclassed, setting WS_EX_NOPARENTNOTIFY on WM_CLOSE doesn't look like a plausible explanation, it's rather a hack that seems to work. Probably it's better to put some effort to figuring out what is going on and how this works on Windows.