[mutter/wip/carlosg/input-in-backends: 29/48] clutter: Remove "has_xinput" x11 API



commit a32559e5aec4cc7a34def723425a72a48c60a759
Author: Carlos Garnacho <carlosg gnome org>
Date:   Tue Mar 26 14:47:59 2019 +0100

    clutter: Remove "has_xinput" x11 API
    
    We always must have xinput, this is moot now.
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/672

 clutter/clutter/x11/clutter-backend-x11.c | 32 -------------------------------
 clutter/clutter/x11/clutter-backend-x11.h |  1 -
 clutter/clutter/x11/clutter-x11.h         |  3 ---
 3 files changed, 36 deletions(-)
---
diff --git a/clutter/clutter/x11/clutter-backend-x11.c b/clutter/clutter/x11/clutter-backend-x11.c
index fa4e9bf16..ac745e6b2 100644
--- a/clutter/clutter/x11/clutter-backend-x11.c
+++ b/clutter/clutter/x11/clutter-backend-x11.c
@@ -250,7 +250,6 @@ clutter_backend_x11_create_device_manager (ClutterBackendX11 *backend_x11)
           if (XIQueryVersion (backend_x11->xdpy, &major, &minor) != BadRequest)
             {
               CLUTTER_NOTE (BACKEND, "Creating XI2 device manager");
-              backend_x11->has_xinput = TRUE;
               backend_x11->device_manager =
                 g_object_new (CLUTTER_TYPE_DEVICE_MANAGER_XI2,
                               "backend", backend_x11,
@@ -265,7 +264,6 @@ clutter_backend_x11_create_device_manager (ClutterBackendX11 *backend_x11)
   if (backend_x11->device_manager == NULL)
     {
       g_critical ("XI2 extension is missing.");
-      backend_x11->has_xinput = FALSE;
       backend_x11->xi_minor = -1;
     }
 
@@ -1164,36 +1162,6 @@ clutter_x11_remove_filter (ClutterX11FilterFunc func,
     }
 }
 
-/**
- * clutter_x11_has_xinput:
- *
- * Gets whether Clutter has XInput support.
- *
- * Return value: %TRUE if Clutter was compiled with XInput support
- *   and XInput support is available at run time.
- *
- * Since: 0.8
- */
-gboolean
-clutter_x11_has_xinput (void)
-{
- ClutterBackend *backend = clutter_get_default_backend ();
-
-  if (backend == NULL)
-    {
-      g_critical ("The Clutter backend has not been initialised");
-      return FALSE;
-    }
-
-  if (!CLUTTER_IS_BACKEND_X11 (backend))
-    {
-      g_critical ("The Clutter backend is not a X11 backend.");
-      return FALSE;
-    }
-
-  return CLUTTER_BACKEND_X11 (backend)->has_xinput;
-}
-
 /**
  * clutter_x11_has_composite_extension:
  *
diff --git a/clutter/clutter/x11/clutter-backend-x11.h b/clutter/clutter/x11/clutter-backend-x11.h
index 3fa74c4c8..d653f8f7f 100644
--- a/clutter/clutter/x11/clutter-backend-x11.h
+++ b/clutter/clutter/x11/clutter-backend-x11.h
@@ -100,7 +100,6 @@ struct _ClutterBackendX11
   Time last_event_time;
 
   ClutterDeviceManager *device_manager;
-  gboolean has_xinput;
   int xi_minor;
 
   XSettingsClient *xsettings;
diff --git a/clutter/clutter/x11/clutter-x11.h b/clutter/clutter/x11/clutter-x11.h
index 6c622c6b0..831f9f30c 100644
--- a/clutter/clutter/x11/clutter-x11.h
+++ b/clutter/clutter/x11/clutter-x11.h
@@ -128,9 +128,6 @@ gboolean clutter_x11_has_event_retrieval (void);
 CLUTTER_EXPORT
 ClutterStage *clutter_x11_get_stage_from_window (Window win);
 
-CLUTTER_EXPORT
-gboolean clutter_x11_has_xinput (void);
-
 CLUTTER_EXPORT
 gboolean clutter_x11_has_composite_extension (void);
 


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