Stefan Hagen wrote (2023-05-01 20:38 CEST):
> there's a bug/annoyance in gnome where newly spawned terminals don't get
> focus: https://gitlab.gnome.org/GNOME/mutter/-/issues/2690
To provide the full picture: The patch I'm proposing reopens the
original issue that lead to the change.
The original issue was, that the launcher looses focus when a window
opens in the background - while the launcher is open.
https://gitlab.gnome.org/GNOME/gnome-shell/-/issues/5932
In my opinion, this is much less problematic than the current behavior.
> For example typing in terminal A, then spawning another terminal B using
> the laucher will make terminal B appear on the screen, but the focus stays
> on terminal A.
>
> I'm currently seeing some people typing stuff into IRC that shouldn't go
> there because of this issue.
>
> Is this something we want to patch until upstream has decided what to
> do about it? The patch restores the previous behavior.
>
> Best Regards,
> Stefan
>
> Index: x11/gnome/mutter/Makefile
> ===================================================================
> RCS file: /cvs/ports/x11/gnome/mutter/Makefile,v
> retrieving revision 1.152
> diff -u -p -u -p -r1.152 Makefile
> --- x11/gnome/mutter/Makefile 26 Apr 2023 08:06:55 -0000 1.152
> +++ x11/gnome/mutter/Makefile 1 May 2023 18:19:40 -0000
> @@ -2,6 +2,7 @@ COMMENT= window and compositing manager
>
> GNOME_PROJECT= mutter
> GNOME_VERSION= 44.1
> +REVISION= 0
>
> SHARED_LIBS += mutter-cogl-12 0.0 # 0.0.0
> SHARED_LIBS += mutter-cogl-pango-12 0.0 # 0.0.0
> Index: x11/gnome/mutter/patches/patch-src_core_window_c
> ===================================================================
> RCS file: x11/gnome/mutter/patches/patch-src_core_window_c
> diff -N x11/gnome/mutter/patches/patch-src_core_window_c
> --- /dev/null 1 Jan 1970 00:00:00 -0000
> +++ x11/gnome/mutter/patches/patch-src_core_window_c 1 May 2023 18:19:40 -0000
> @@ -0,0 +1,20 @@
> +Fix focus issue: https://gitlab.gnome.org/GNOME/mutter/-/issues/2690
> +Index: src/core/window.c
> +--- src/core/window.c.orig
> ++++ src/core/window.c
> +@@ -1998,15 +1998,6 @@ window_state_on_map (MetaWindow *window,
> + return;
> + }
> +
> +- /* Do not focus window on map if input is already taken by the
> +- * compositor.
> +- */
> +- if (!meta_display_windows_are_interactable (window->display))
> +- {
> +- *takes_focus = FALSE;
> +- return;
> +- }
> +-
> + /* Terminal usage may be different; some users intend to launch
> + * many apps in quick succession or to just view things in the new
> + * window while still interacting with the terminal. In that case,
>
No comments:
Post a Comment