[mutter/wip/fmuellner/contraint-tiling: 10/15] window: Raise and lower tile match in tandem
- From: Florian Müllner <fmuellner src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/wip/fmuellner/contraint-tiling: 10/15] window: Raise and lower tile match in tandem
- Date: Tue, 3 Oct 2017 18:26:19 +0000 (UTC)
commit b7a9c0500ac2d56a5327096ccd66a3b534e62a5b
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date: Thu Jun 15 19:52:13 2017 -0300
window: Raise and lower tile match in tandem
When a pair of tiled windows are grouped together, they
are treated as parts of a whole and interacting with one
affects the other.
Following the idea that sibling tiled windows are treated
as part of the same group, they should also be raised and
lowered together.
It is still possible to break tiled windows grouping by
simply untiling the window with the keyboard or by grabbing
and resizing or moving the window with the cursor.
This patch makes sibling tiled windows be lowered and raised
in tandem. For future reference, this behavior is documented
in [1].
[1] https://wiki.gnome.org/GeorgesNeto/MinutesOfFeaneron/Tiling
https://bugzilla.gnome.org/show_bug.cgi?id=645153
src/core/window.c | 12 +++++++++++-
1 files changed, 11 insertions(+), 1 deletions(-)
---
diff --git a/src/core/window.c b/src/core/window.c
index c096d2d..ba908c9 100644
--- a/src/core/window.c
+++ b/src/core/window.c
@@ -4866,7 +4866,13 @@ meta_window_raise (MetaWindow *window)
* the child windows appropriately.
*/
if (window->screen->stack == ancestor->screen->stack)
- meta_stack_raise (window->screen->stack, ancestor);
+ {
+ /* If the window has a tile sibling, raise it before raising the window itself */
+ if (window->tile_match)
+ meta_stack_raise (window->tile_match->screen->stack, window->tile_match);
+
+ meta_stack_raise (window->screen->stack, ancestor);
+ }
else
{
meta_warning (
@@ -4898,6 +4904,10 @@ meta_window_lower (MetaWindow *window)
meta_topic (META_DEBUG_WINDOW_OPS,
"Lowering window %s\n", window->desc);
+ /* If the window has a tile sibling, lower it before loweting the window itself */
+ if (window->tile_match)
+ meta_stack_lower (window->tile_match->screen->stack, window->tile_match);
+
meta_stack_lower (window->screen->stack, window);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]