From d2795e5cb5242f84f7279d9b58d5e3108f394102 Mon Sep 17 00:00:00 2001 From: Simon Tatham Date: Sat, 22 Oct 2022 07:46:44 +0100 Subject: Fix build with GTK3 prior to 3.22.23. Those versions of GTK (or rather, GDK) don't support the GDK_WINDOW_STATE_TOP_TILED constants; they only support the non-directional GDK_WINDOW_STATE_TILED. And GTK < 3.10.0 doesn't even support that. All those constants were under #ifdef already; I've just made the ifdefs a bit more precise. --- unix/window.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/unix/window.c b/unix/window.c index 1958edde..18cce475 100644 --- a/unix/window.c +++ b/unix/window.c @@ -2557,8 +2557,10 @@ static void request_resize_internal(GtkFrontend *inst, bool from_terminal, GdkWindowState state = gdk_window_get_state(gdkwin); if (state & (GDK_WINDOW_STATE_MAXIMIZED | GDK_WINDOW_STATE_FULLSCREEN | -#if GTK_CHECK_VERSION(3,0,0) +#if GTK_CHECK_VERSION(3,10,0) GDK_WINDOW_STATE_TILED | +#endif +#if GTK_CHECK_VERSION(3,22,23) GDK_WINDOW_STATE_TOP_TILED | GDK_WINDOW_STATE_RIGHT_TILED | GDK_WINDOW_STATE_BOTTOM_TILED | -- cgit v1.2.3