diff --git a/src/xterm.c b/src/xterm.c index fd3e58f85f6..3087e10dddf 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -18041,7 +18041,12 @@ x_net_wm_state (struct frame *f, Window window) break; } - store_frame_param (f, Qfullscreen, lval); + if (EQ (get_frame_param (f, Qfullscreen), Qfullheight) + || EQ (lval, Qfullheight)) + store_frame_param (f, Qfullscreen, lval); // break here + else + store_frame_param (f, Qfullscreen, lval); + store_frame_param (f, Qsticky, sticky ? Qt : Qnil); store_frame_param (f, Qshaded, shaded ? Qt : Qnil); } @@ -28272,7 +28277,12 @@ x_handle_net_wm_state (struct frame *f, const XPropertyEvent *event) break; } - store_frame_param (f, Qfullscreen, lval); + if (EQ (get_frame_param (f, Qfullscreen), Qfullheight) + || EQ (lval, Qfullheight)) + store_frame_param (f, Qfullscreen, lval); // break here + else + store_frame_param (f, Qfullscreen, lval); + store_frame_param (f, Qsticky, sticky ? Qt : Qnil); store_frame_param (f, Qshaded, shaded ? Qt : Qnil); @@ -28340,7 +28350,11 @@ x_check_fullscreen (struct frame *f) /* `x_net_wm_state' might have reset the fullscreen frame parameter, restore it. */ - store_frame_param (f, Qfullscreen, lval); + if (EQ (get_frame_param (f, Qfullscreen), Qfullheight) + || EQ (lval, Qfullheight)) + store_frame_param (f, Qfullscreen, lval); // break here + else + store_frame_param (f, Qfullscreen, lval); } /* This function is called by x_set_offset to determine whether the window