forked from AuroraMiddleware/gtk
x11: fix crash on idle compute size without layout
On x11 toplevel layout is not created before toplevel is presented, but GTK tries to update it on idle which leads to a crash due to accessing property of undefined object. Treat soon to be created layout as a layout with default values upon creation (resizable).
This commit is contained in:
parent
51a6b29e01
commit
53af35d256
@ -291,7 +291,7 @@ compute_toplevel_size (GdkSurface *surface,
|
|||||||
GdkGeometry geometry;
|
GdkGeometry geometry;
|
||||||
GdkSurfaceHints mask;
|
GdkSurfaceHints mask;
|
||||||
|
|
||||||
if (gdk_toplevel_layout_get_resizable (impl->toplevel_layout))
|
if (!impl->toplevel_layout || gdk_toplevel_layout_get_resizable (impl->toplevel_layout))
|
||||||
{
|
{
|
||||||
geometry.min_width = size.min_width;
|
geometry.min_width = size.min_width;
|
||||||
geometry.min_height = size.min_height;
|
geometry.min_height = size.min_height;
|
||||||
|
Loading…
Reference in New Issue
Block a user