[mutter] clutter: Remove Wayland server helper



commit b578a534a340edbe1ce7ca72a32ea002fdcc8458
Author: Jonas Ã…dahl <jadahl gmail com>
Date:   Thu May 6 14:48:49 2021 +0200

    clutter: Remove Wayland server helper
    
    It's a wrapper around a similar Cogl API we don't use anymore.
    
    Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1863>

 clutter/clutter/clutter-backend.c                  | 46 ----------------------
 clutter/clutter/clutter-config.h.in                |  1 -
 clutter/clutter/meson.build                        | 10 -----
 .../clutter/wayland/clutter-wayland-compositor.h   | 45 ---------------------
 src/wayland/meta-wayland-surface.c                 |  1 -
 5 files changed, 103 deletions(-)
---
diff --git a/clutter/clutter/clutter-backend.c b/clutter/clutter/clutter-backend.c
index c90fabb422..af806c0516 100644
--- a/clutter/clutter/clutter-backend.c
+++ b/clutter/clutter/clutter-backend.c
@@ -50,18 +50,8 @@
 #include "clutter-stage-private.h"
 #include "clutter-stage-window.h"
 
-#ifdef CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT
-#include "wayland/clutter-wayland-compositor.h"
-#endif
-
 #include <cogl/cogl.h>
 
-#ifdef CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT
-#include <cogl/cogl-wayland-server.h>
-#include <wayland-server.h>
-#include "wayland/clutter-wayland-compositor.h"
-#endif
-
 #define DEFAULT_FONT_NAME       "Sans 10"
 
 enum
@@ -77,12 +67,6 @@ G_DEFINE_ABSTRACT_TYPE (ClutterBackend, clutter_backend, G_TYPE_OBJECT)
 
 static guint backend_signals[LAST_SIGNAL] = { 0, };
 
-/* Global for being able to specify a compositor side wayland display
- * pointer before clutter initialization */
-#ifdef CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT
-static struct wl_display *_wayland_compositor_display;
-#endif
-
 static void
 clutter_backend_dispose (GObject *gobject)
 {
@@ -262,11 +246,6 @@ clutter_backend_do_real_create_context (ClutterBackend  *backend,
   if (backend->cogl_display == NULL)
     goto error;
 
-#ifdef CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT
-  cogl_wayland_display_set_compositor_display (backend->cogl_display,
-                                               _wayland_compositor_display);
-#endif
-
   CLUTTER_NOTE (BACKEND, "Setting up the display");
   if (!cogl_display_setup (backend->cogl_display, &internal_error))
     goto error;
@@ -818,31 +797,6 @@ clutter_backend_get_cogl_context (ClutterBackend *backend)
   return backend->cogl_context;
 }
 
-#ifdef CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT
-/**
- * clutter_wayland_set_compositor_display:
- * @display: A compositor side struct wl_display pointer
- *
- * This informs Clutter of your compositor side Wayland display
- * object. This must be called before calling clutter_init().
- *
- * Since: 1.8
- * Stability: unstable
- */
-void
-clutter_wayland_set_compositor_display (void *display)
-{
-  if (_clutter_context_is_initialized ())
-    {
-      g_warning ("%s() can only be used before calling clutter_init()",
-                 G_STRFUNC);
-      return;
-    }
-
-  _wayland_compositor_display = display;
-}
-#endif
-
 void
 clutter_set_allowed_drivers (const char *drivers)
 {
diff --git a/clutter/clutter/clutter-config.h.in b/clutter/clutter/clutter-config.h.in
index ebf523d1d0..b3057f4ae9 100644
--- a/clutter/clutter/clutter-config.h.in
+++ b/clutter/clutter/clutter-config.h.in
@@ -9,7 +9,6 @@
 
 G_BEGIN_DECLS
 
-#mesondefine CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT
 #mesondefine CLUTTER_WINDOWING_X11
 #mesondefine CLUTTER_INPUT_X11
 #mesondefine CLUTTER_WINDOWING_GLX
diff --git a/clutter/clutter/meson.build b/clutter/clutter/meson.build
index a3bbfc1134..af3cf24e0b 100644
--- a/clutter/clutter/meson.build
+++ b/clutter/clutter/meson.build
@@ -264,13 +264,6 @@ if have_x11
   clutter_backend_nonintrospected_sources += clutter_x11_nonintrospected_sources
 endif
 
-if have_wayland
-  clutter_wayland_private_headers = [
-    'wayland/clutter-wayland-compositor.h',
-  ]
-  clutter_backend_private_headers += clutter_wayland_private_headers
-endif
-
 cally_headers = [
     'cally/cally-actor.h',
     'cally/cally-clone.h',
@@ -317,9 +310,6 @@ clutter_build_config_h = configure_file(
 clutter_built_private_headers += clutter_build_config_h
 
 cdata = configuration_data()
-if have_wayland
-  cdata.set10('CLUTTER_HAS_WAYLAND_COMPOSITOR_SUPPORT', true)
-endif
 if have_x11
   cdata.set_quoted('CLUTTER_WINDOWING_X11', 'x11')
   cdata.set_quoted('CLUTTER_INPUT_X11', 'x11')
diff --git a/src/wayland/meta-wayland-surface.c b/src/wayland/meta-wayland-surface.c
index 8dbf3a7505..64e7de8db2 100644
--- a/src/wayland/meta-wayland-surface.c
+++ b/src/wayland/meta-wayland-surface.c
@@ -29,7 +29,6 @@
 
 #include "backends/meta-cursor-tracker-private.h"
 #include "clutter/clutter.h"
-#include "clutter/wayland/clutter-wayland-compositor.h"
 #include "cogl/cogl-wayland-server.h"
 #include "cogl/cogl.h"
 #include "compositor/meta-surface-actor-wayland.h"


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