Commit 6dede1a0 authored by LRN's avatar LRN

W32: Don't crash when opacity is set for non-toplevel

X11 backend doesn't, and for good reason - main code body does not check
that the window it sets opacity for is, in fact, toplevel.
Just silently fail to do anything for non-toplevel windows.

https://bugzilla.gnome.org/show_bug.cgi?id=733769
parent bbe475fd
......@@ -3175,9 +3175,8 @@ gdk_win32_window_set_opacity (GdkWindow *window,
PFN_SetLayeredWindowAttributes setLayeredWindowAttributes = NULL;
g_return_if_fail (GDK_IS_WINDOW (window));
g_return_if_fail (WINDOW_IS_TOPLEVEL (window));
if (GDK_WINDOW_DESTROYED (window))
if (!WINDOW_IS_TOPLEVEL (window) || GDK_WINDOW_DESTROYED (window))
return;
if (opacity < 0)
......
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