|
|
762b62 |
From 2e3ae76207d9367fa15a3e759e797a0bea5eea71 Mon Sep 17 00:00:00 2001
|
|
|
762b62 |
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
|
|
762b62 |
Date: Fri, 25 May 2018 20:18:23 +0200
|
|
|
762b62 |
Subject: [PATCH 1/2] window: Don't refuse to move focus to the grab window
|
|
|
762b62 |
|
|
|
762b62 |
We refuse to move focus while a grab operation is in place. While this
|
|
|
762b62 |
generally makes sense, there's no reason why the window that owns the
|
|
|
762b62 |
grab shouldn't be given the regular input focus as well - we pretty
|
|
|
762b62 |
much assume that the grab window is also the focus window anyway.
|
|
|
762b62 |
|
|
|
762b62 |
In fact there's a strong reason for allowing the focus change here:
|
|
|
762b62 |
If the grab window isn't the focus window, it probably has a modal
|
|
|
762b62 |
transient that is focused instead, and a likely reason for the focus
|
|
|
762b62 |
request is that the transient is being unmanaged and we must move
|
|
|
762b62 |
the focus elsewhere.
|
|
|
762b62 |
|
|
|
762b62 |
https://gitlab.gnome.org/GNOME/mutter/issues/15
|
|
|
762b62 |
---
|
|
|
762b62 |
src/core/window.c | 1 +
|
|
|
762b62 |
1 file changed, 1 insertion(+)
|
|
|
762b62 |
|
|
|
762b62 |
diff --git a/src/core/window.c b/src/core/window.c
|
|
|
762b62 |
index c2d9869d2..80144cc63 100644
|
|
|
762b62 |
--- a/src/core/window.c
|
|
|
762b62 |
+++ b/src/core/window.c
|
|
|
762b62 |
@@ -4601,6 +4601,7 @@ meta_window_focus (MetaWindow *window,
|
|
|
762b62 |
window->desc, window->input, window->take_focus);
|
|
|
762b62 |
|
|
|
762b62 |
if (window->display->grab_window &&
|
|
|
762b62 |
+ window->display->grab_window != window &&
|
|
|
762b62 |
window->display->grab_window->all_keys_grabbed &&
|
|
|
762b62 |
!window->display->grab_window->unmanaging)
|
|
|
762b62 |
{
|
|
|
762b62 |
--
|
|
|
762b62 |
2.17.1
|
|
|
762b62 |
|
|
|
762b62 |
|
|
|
762b62 |
From ba49c5298b1ae3a1e1ba52ec16d5a739115e6967 Mon Sep 17 00:00:00 2001
|
|
|
762b62 |
From: =?UTF-8?q?Florian=20M=C3=BCllner?= <fmuellner@gnome.org>
|
|
|
762b62 |
Date: Fri, 25 May 2018 21:24:17 +0200
|
|
|
762b62 |
Subject: [PATCH 2/2] window: Explicitly exclude unmanaging window from focus
|
|
|
762b62 |
again
|
|
|
762b62 |
|
|
|
762b62 |
Since commit b3b9d9e16 we no longer have to pass the unmanaging window
|
|
|
762b62 |
to make sure we don't try to focus it again, however the parameter also
|
|
|
762b62 |
influences the focus policy by giving ancestors preference over the normal
|
|
|
762b62 |
stack order.
|
|
|
762b62 |
|
|
|
762b62 |
https://gitlab.gnome.org/GNOME/mutter/issues/15
|
|
|
762b62 |
---
|
|
|
762b62 |
src/core/window.c | 4 +++-
|
|
|
762b62 |
1 file changed, 3 insertions(+), 1 deletion(-)
|
|
|
762b62 |
|
|
|
762b62 |
diff --git a/src/core/window.c b/src/core/window.c
|
|
|
762b62 |
index 80144cc63..0b71744d5 100644
|
|
|
762b62 |
--- a/src/core/window.c
|
|
|
762b62 |
+++ b/src/core/window.c
|
|
|
762b62 |
@@ -1466,7 +1466,9 @@ meta_window_unmanage (MetaWindow *window,
|
|
|
762b62 |
meta_topic (META_DEBUG_FOCUS,
|
|
|
762b62 |
"Focusing default window since we're unmanaging %s\n",
|
|
|
762b62 |
window->desc);
|
|
|
762b62 |
- meta_workspace_focus_default_window (window->screen->active_workspace, NULL, timestamp);
|
|
|
762b62 |
+ meta_workspace_focus_default_window (window->screen->active_workspace,
|
|
|
762b62 |
+ window,
|
|
|
762b62 |
+ timestamp);
|
|
|
762b62 |
}
|
|
|
762b62 |
else
|
|
|
762b62 |
{
|
|
|
762b62 |
--
|
|
|
762b62 |
2.17.1
|
|
|
762b62 |
|