[mutter] wayland/window: Provide prior floating window dimensions
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] wayland/window: Provide prior floating window dimensions
- Date: Thu, 22 Oct 2020 16:35:29 +0000 (UTC)
commit a93ef84d577621359e667c86342fdd37c2bcd14e
Author: Christian Rauch <Rauch Christian gmx de>
Date: Wed Sep 18 23:59:50 2019 +0100
wayland/window: Provide prior floating window dimensions
Implements the "prior window window geometry dimensions" as described in
the documentation of 'xdg_toplevel' request 'unset_maximized':
"If available and applicable, the compositor will include the window
geometry dimensions the window had prior to being maximized in the
configure event."
and 'unset_fullscreen':
"The compositor may include the previous window geometry dimensions in
the configure event, if applicable."
Fixes https://gitlab.gnome.org/GNOME/mutter/issues/792.
src/wayland/meta-window-wayland.c | 20 ++------------------
1 file changed, 2 insertions(+), 18 deletions(-)
---
diff --git a/src/wayland/meta-window-wayland.c b/src/wayland/meta-window-wayland.c
index 6f778568dd..afb529cce6 100644
--- a/src/wayland/meta-window-wayland.c
+++ b/src/wayland/meta-window-wayland.c
@@ -256,24 +256,8 @@ meta_window_wayland_move_resize_internal (MetaWindow *window,
* to the Wayland surface. */
geometry_scale = meta_window_wayland_get_geometry_scale (window);
- if (flags & META_MOVE_RESIZE_UNMAXIMIZE &&
- !meta_window_is_fullscreen (window))
- {
- configured_width = 0;
- configured_height = 0;
- }
- else if (flags & META_MOVE_RESIZE_UNFULLSCREEN &&
- !meta_window_get_maximized (window) &&
- meta_window_get_tile_mode (window) == META_TILE_NONE)
- {
- configured_width = 0;
- configured_height = 0;
- }
- else
- {
- configured_width = constrained_rect.width / geometry_scale;
- configured_height = constrained_rect.height / geometry_scale;
- }
+ configured_width = constrained_rect.width / geometry_scale;
+ configured_height = constrained_rect.height / geometry_scale;
/* For wayland clients, the size is completely determined by the client,
* and while this allows to avoid some trickery with frames and the resulting
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]