1
0
Fork 0
mutter-performance-source/src/core
Carlos Garnacho a68b8e9595 x11: Do not move X11 input focus during grabs
On X11, the stage itself is backed by an XWindow, and moving the
input focus elsewhere will bypass any Clutter-level grabs.

This effectively allows newly opened windows to steal the focus
from gnome-shell itself, which is clearly undesirable. To prevent
that, only allow moving the X11 focus to a Window when no grab is
in place, just like commit 50e89e376 did for the stage focus.

But particularly the updating of x11_display->focus_xwindow is not
prevented. Since it's more consistent to the MetaDisplay/MetaX11Display
dual focus tracking and across Wayland/X11 backends, ensure the X11
input focus is actually set on the last focus Window after the
grabs are gone and windows became interactable again.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2832>
2023-02-13 12:45:37 +00:00
..
bell.c *: Fix spelling mistakes found by codespell 2020-08-29 09:10:31 +00:00
bell.h frame: Remove flashing support 2019-03-12 00:27:07 +00:00
boxes-private.h boxes: Add function to check if rectangle is adjacent to region 2021-08-04 14:02:16 +00:00
boxes.c core: Cleanup header includes 2023-01-30 10:56:29 +00:00
constraints.c core,wayland,compositor,x11: Migrate to MetaWindowDrag 2023-01-30 10:56:29 +00:00
constraints.h window: Implement asynchronous popup moving 2020-02-29 21:01:50 +00:00
delete.c core/delete: Avoid warnings when there is no close dialog 2023-01-30 13:17:19 +00:00
display-private.h x11: Handle accounting of ignored serials in X11 code 2023-02-09 14:38:39 +01:00
display.c Revert "display: Do not move X11 input focus during grabs" 2023-02-13 12:45:37 +00:00
events.c x11: Do not move X11 input focus during grabs 2023-02-13 12:45:37 +00:00
events.h core: Add a copy of GDK_PRIORITY_EVENTS 2022-12-22 15:13:54 +01:00
frame.c core: Update frame opaque region from _NET_WM_OPAQUE_REGION property 2023-01-20 22:23:55 +00:00
frame.h core: Add infrastructure to keep window frames' opaque regions 2023-01-20 22:23:55 +00:00
keybindings-private.h core: Delete now unused code 2023-01-30 10:56:29 +00:00
keybindings.c core: Move edge-resistance handling to src/compositor 2023-01-30 10:56:29 +00:00
meta-accel-parse.c core: Replace MetaVirtualModifier 2022-12-22 15:13:54 +01:00
meta-accel-parse.h core: Replace MetaVirtualModifier 2022-12-22 15:13:54 +01:00
meta-anonymous-file.c Add read-only anonymous file abstraction MetaAnonymousFile 2020-04-21 17:52:08 +02:00
meta-anonymous-file.h Add read-only anonymous file abstraction MetaAnonymousFile 2020-04-21 17:52:08 +02:00
meta-border.c MetaBorder: Use float constants and functions instead of double variants 2016-02-16 19:02:48 +08:00
meta-border.h Move out generic math parts out of the native barrier implementation 2016-02-16 19:02:48 +08:00
meta-clipboard-manager.c core: Setup and use ownership chains 2022-12-17 15:13:48 +01:00
meta-clipboard-manager.h core: Add clipboard manager 2019-05-02 16:22:45 +02:00
meta-close-dialog.c Use a consistent style for enum braces 2019-02-28 09:31:01 +01:00
meta-context-main.c core: Setup and use ownership chains 2022-12-17 15:13:48 +01:00
meta-context-main.h Introduce MetaContextMain 2021-07-15 11:25:21 +02:00
meta-context-private.h x11: Let X11 connection owners call XSynchronize() themselves 2022-06-03 13:43:26 +00:00
meta-context.c context: Add 'started' and 'prepare-shutdown' signals 2022-11-25 10:26:52 +00:00
meta-fraction.c Add MetaFraction for dealing with fractions 2017-08-29 14:39:04 +08:00
meta-fraction.h Add MetaFraction for dealing with fractions 2017-08-29 14:39:04 +08:00
meta-gesture-tracker-private.h display: Move finishing of touch sequence to the backend 2019-10-28 18:40:43 +00:00
meta-gesture-tracker.c events: Make MetaGestureTracker work with the action event delivery 2023-02-03 12:10:22 +00:00
meta-inhibit-shortcuts-dialog-default-private.h Clean up include macros mess 2018-11-06 17:17:36 +01:00
meta-inhibit-shortcuts-dialog-default.c Use a consistent style for enum braces 2019-02-28 09:31:01 +01:00
meta-inhibit-shortcuts-dialog.c core: add MetaInhibitShortcutsDialog 2017-08-02 11:58:55 +02:00
meta-launch-context.c core: Setup and use ownership chains 2022-12-17 15:13:48 +01:00
meta-pad-action-mapper.c core: Replace MetaVirtualModifier 2022-12-22 15:13:54 +01:00
meta-pad-action-mapper.h backends: Split pad action mapping to a separate object 2020-11-27 15:14:33 +00:00
meta-private-enums.h window: Move some display level window processing to MetaDisplay 2022-02-07 17:52:05 +00:00
meta-profiler.c profiler: Allow enable tracing via env var 2022-11-01 21:04:21 +00:00
meta-profiler.h Move MetaProfiler from the backend to core 2022-11-01 21:04:21 +00:00
meta-selection-private.h core: Setup and use ownership chains 2022-12-17 15:13:48 +01:00
meta-selection-source-memory.c core: Fix task leak in meta_selection_source_memory_read_async 2020-02-01 14:02:19 +00:00
meta-selection-source-remote.c remote-desktop/session: Add support for SelectionTransfer/Write 2021-02-05 16:44:27 +00:00
meta-selection-source-remote.h remote-desktop/session: Add support for SelectionTransfer/Write 2021-02-05 16:44:27 +00:00
meta-selection-source.c Make MetaSelection, MetaSelectionSource and MetaMemorySelectionSource public 2019-05-02 16:31:45 +02:00
meta-selection.c core/selection: Set display on creation 2022-12-17 16:47:46 +01:00
meta-sound-player.c sound player: Don't unref undefined fields 2022-11-23 10:37:19 +01:00
meta-workspace-manager-private.h tests/stacking: Add workspace management commands 2022-09-20 17:14:53 +00:00
meta-workspace-manager.c util: Remove push/pop no msg prefix logging 2021-11-21 20:53:33 +00:00
mutter.c mutter: Raise the NOFILE limit if a Wayland compositor 2022-02-07 16:11:47 +01:00
place.c cleanup: Make GDK dependency specific to X11 2022-12-22 15:09:03 +01:00
place.h place: Make placement rule processing provide relative coordinates 2020-02-29 21:01:50 +00:00
prefs-private.h prefs: Make init function private 2021-05-17 16:08:42 +00:00
prefs.c core: Replace MetaVirtualModifier 2022-12-22 15:13:54 +01:00
restart-helper.c Clean up include macros mess 2018-11-06 17:17:36 +01:00
restart.c ui: Excise old frames UI 2022-12-01 20:10:53 +00:00
stack-tracker.c compositor: Don't make internal API public 2022-12-17 15:13:48 +01:00
stack-tracker.h meta: Hide libmutter symbols by default and selectively export them 2019-01-23 14:18:13 +01:00
stack.c core: Move remaining default focus window handling to workspace 2022-09-20 17:14:53 +00:00
stack.h core: Move remaining default focus window handling to workspace 2022-09-20 17:14:53 +00:00
startup-notification-private.h core: Setup and use ownership chains 2022-12-17 15:13:48 +01:00
startup-notification.c core: Setup and use ownership chains 2022-12-17 15:13:48 +01:00
util-private.h util: Remove left-over declaration 2022-09-19 14:46:01 +00:00
util.c core: Cleanup header includes 2023-01-30 10:56:29 +00:00
window-private.h core: Move accounting of "shaken_loose" to MetaWindowDrag 2023-01-30 10:56:29 +00:00
window.c x11: Reset ignored crossing serials from X11 code 2023-02-09 14:38:39 +01:00
workspace-private.h core: Move remaining default focus window handling to workspace 2022-09-20 17:14:53 +00:00
workspace.c workspace: Do not raise default focus window with raise-on-click 2023-02-03 17:09:12 +00:00