[mutter/cherry-pick-70e44c28] backends: Do not try to move pointer onscreen in common code



commit d90df7b694db5379a5dbcb506a5f4be058fcdbcd
Author: Carlos Garnacho <carlosg gnome org>
Date:   Fri Jan 14 20:32:37 2022 +0100

    backends: Do not try to move pointer onscreen in common code
    
    This is now handled inside the input thread in the native backend,
    and X11 has always done something similar to this. This common code
    is no longer necessary.
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2237>
    (cherry picked from commit 5e3f89e3425772e06429204df0e6717748bf48e0)

 src/backends/meta-backend.c | 21 ---------------------
 1 file changed, 21 deletions(-)
---
diff --git a/src/backends/meta-backend.c b/src/backends/meta-backend.c
index 87e0b3bba1..f11ac014c8 100644
--- a/src/backends/meta-backend.c
+++ b/src/backends/meta-backend.c
@@ -349,28 +349,7 @@ update_cursors (MetaBackend *backend)
 void
 meta_backend_monitors_changed (MetaBackend *backend)
 {
-  MetaBackendPrivate *priv = meta_backend_get_instance_private (backend);
-  MetaMonitorManager *monitor_manager =
-    meta_backend_get_monitor_manager (backend);
-  ClutterSeat *seat = priv->default_seat;
-  ClutterInputDevice *device = clutter_seat_get_pointer (seat);
-  graphene_point_t point;
-
   meta_backend_sync_screen_size (backend);
-
-  if (clutter_seat_query_state (seat, device, NULL, &point, NULL))
-    {
-      /* If we're outside all monitors, warp the pointer back inside */
-      if ((!meta_monitor_manager_get_logical_monitor_at (monitor_manager,
-                                                         point.x, point.y) ||
-           !priv->is_pointer_position_initialized) &&
-          !meta_monitor_manager_is_headless (monitor_manager))
-        {
-          reset_pointer_position (backend);
-          priv->is_pointer_position_initialized = TRUE;
-        }
-    }
-
   update_cursors (backend);
 }
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]