[mutter] stack: Stack docks below other windows on fullscreen monitors
- From: Rui Matos <rtcm src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter] stack: Stack docks below other windows on fullscreen monitors
- Date: Wed, 2 Nov 2016 13:15:55 +0000 (UTC)
commit bfb46ff85041b04538d899c581056c77214e3ae0
Author: Rui Matos <tiagomatos gmail com>
Date: Mon Oct 24 17:09:46 2016 +0200
stack: Stack docks below other windows on fullscreen monitors
Commit fcc7501eb8dab5c1749e5421e31311fd14fd73f0 had the side-effect of
stacking fullscreen windows below docks which went unnoticed since we
don't use docks in GNOME anymore.
Instead of re-introducing the fullscreen layer, which we don't need
otherwise, we can fix this issue by ensuring we stack docks below all
other windows when the monitor they're on is marked fullscreen. This
has the added benefit that the visibility rule for 3rd party docks
becomes the same as gnome-shell's chrome.
https://bugzilla.gnome.org/show_bug.cgi?id=772937
src/core/screen.c | 10 +++++++++-
src/core/stack.c | 4 ++--
2 files changed, 11 insertions(+), 3 deletions(-)
---
diff --git a/src/core/screen.c b/src/core/screen.c
index 4fbf224..b8ac22f 100644
--- a/src/core/screen.c
+++ b/src/core/screen.c
@@ -2888,7 +2888,15 @@ check_fullscreen_func (gpointer data)
g_slist_free (fullscreen_monitors);
if (in_fullscreen_changed)
- g_signal_emit (screen, screen_signals[IN_FULLSCREEN_CHANGED], 0, NULL);
+ {
+ /* DOCK window stacking depends on the monitor's fullscreen
+ status so we need to trigger a re-layering. */
+ MetaWindow *window = meta_stack_get_top (screen->stack);
+ if (window)
+ meta_stack_update_layer (screen->stack, window);
+
+ g_signal_emit (screen, screen_signals[IN_FULLSCREEN_CHANGED], 0, NULL);
+ }
return FALSE;
}
diff --git a/src/core/stack.c b/src/core/stack.c
index 1375f26..a9f6d1d 100644
--- a/src/core/stack.c
+++ b/src/core/stack.c
@@ -286,8 +286,8 @@ get_standalone_layer (MetaWindow *window)
break;
case META_WINDOW_DOCK:
- /* still experimenting here */
- if (window->wm_state_below)
+ if (window->wm_state_below ||
+ (window->monitor && window->monitor->in_fullscreen))
layer = META_LAYER_BOTTOM;
else
layer = META_LAYER_DOCK;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]