[mutter] cogl: Remove unused API from cogl-xlib



commit ac626f7334b40d3198eb75b0d70b62b9e72671ff
Author: Adam Jackson <ajax redhat com>
Date:   Thu Oct 24 15:33:54 2019 -0400

    cogl: Remove unused API from cogl-xlib
    
    https://gitlab.gnome.org/GNOME/mutter/merge_requests/885

 cogl/cogl/cogl-context-private.h |  1 -
 cogl/cogl/cogl-xlib-private.h    |  3 ---
 cogl/cogl/cogl-xlib.c            | 47 ---------------------------------
 cogl/cogl/cogl-xlib.h            | 56 ----------------------------------------
 4 files changed, 107 deletions(-)
---
diff --git a/cogl/cogl/cogl-context-private.h b/cogl/cogl/cogl-context-private.h
index 426b69166..04040ce8c 100644
--- a/cogl/cogl/cogl-context-private.h
+++ b/cogl/cogl/cogl-context-private.h
@@ -292,7 +292,6 @@ struct _CoglContext
    * the eglx backend doesn't yet have a corresponding Cogl winsys
    * and so we wont have a renderer in that case. */
 #ifdef COGL_HAS_XLIB_SUPPORT
-  int damage_base;
   /* List of callback functions that will be given every Xlib event */
   GSList *event_filters;
   /* Current top of the XError trap state stack. The actual memory for
diff --git a/cogl/cogl/cogl-xlib-private.h b/cogl/cogl/cogl-xlib-private.h
index 992a32099..8bf23a7e1 100644
--- a/cogl/cogl/cogl-xlib-private.h
+++ b/cogl/cogl/cogl-xlib-private.h
@@ -45,9 +45,6 @@ struct _CoglXlibTrapState
   CoglXlibTrapState *old_state;
 };
 
-void
-_cogl_xlib_query_damage_extension (void);
-
 int
 _cogl_xlib_get_damage_base (void);
 
diff --git a/cogl/cogl/cogl-xlib.c b/cogl/cogl/cogl-xlib.c
index 4b10f518c..feb684b37 100644
--- a/cogl/cogl/cogl-xlib.c
+++ b/cogl/cogl/cogl-xlib.c
@@ -51,53 +51,6 @@
  * _cogl_xlib_renderer API
  */
 
-/* This can't be in the Cogl context because it can be set before
-   context is created */
-static Display *_cogl_xlib_display = NULL;
-
-Display *
-cogl_xlib_get_display (void)
-{
-  _COGL_GET_CONTEXT (ctx, NULL);
-
-  return cogl_xlib_renderer_get_display (ctx->display->renderer);
-}
-
-void
-cogl_xlib_set_display (Display *display)
-{
-  /* This can only be called once before the Cogl context is created */
-  g_assert (_cogl_xlib_display == NULL);
-
-  _cogl_xlib_display = display;
-}
-
-/* These three functions are wrappers around the equivalent renderer
-   functions. They can be removed once all xlib-based backends in
-   Clutter know about the renderer */
-CoglFilterReturn
-cogl_xlib_handle_event (XEvent *xevent)
-{
-  _COGL_GET_CONTEXT (ctx, COGL_FILTER_CONTINUE);
-
-  /* Pass the event on to the renderer */
-  return cogl_xlib_renderer_handle_event (ctx->display->renderer, xevent);
-}
-
-void
-_cogl_xlib_query_damage_extension (void)
-{
-  int damage_error;
-  Display *display;
-
-  _COGL_GET_CONTEXT (ctxt, NO_RETVAL);
-
-  /* Check whether damage events are supported on this display */
-  display = cogl_xlib_renderer_get_display (ctxt->display->renderer);
-  if (!XDamageQueryExtension (display, &ctxt->damage_base, &damage_error))
-    ctxt->damage_base = -1;
-}
-
 int
 _cogl_xlib_get_damage_base (void)
 {
diff --git a/cogl/cogl/cogl-xlib.h b/cogl/cogl/cogl-xlib.h
index bb15183be..7136a943b 100644
--- a/cogl/cogl/cogl-xlib.h
+++ b/cogl/cogl/cogl-xlib.h
@@ -59,62 +59,6 @@
 #include <cogl/cogl-xlib-renderer.h>
 #include <cogl/cogl-macros.h>
 
-G_BEGIN_DECLS
-
-/*
- * cogl_xlib_get_display:
- *
- * Return value: the Xlib display that will be used by the Xlib winsys
- * backend. The display needs to be set with _cogl_xlib_set_display()
- * before this function is called.
- *
- * Stability: Unstable
- * Deprecated: 1.16: Use cogl_xlib_renderer_get_display() instead
- */
-COGL_DEPRECATED_FOR (cogl_xlib_renderer_get_display)
-Display *
-cogl_xlib_get_display (void);
-
-/*
- * cogl_xlib_set_display:
- *
- * Sets the Xlib display that Cogl will use for the Xlib winsys
- * backend. This function should eventually go away when Cogl gains a
- * more complete winsys abstraction.
- *
- * Stability: Unstable
- * Deprecated: 1.16: Use cogl_xlib_renderer_set_foreign_display()
- *                   instead
- */
-COGL_DEPRECATED_FOR (cogl_xlib_renderer_set_foreign_display)
-void
-cogl_xlib_set_display (Display *display);
-
-/*
- * cogl_xlib_handle_event:
- * @xevent: pointer to XEvent structure
- *
- * This function processes a single X event; it can be used to hook
- * into external X event retrieval (for example that done by Clutter
- * or GDK).
- *
- * Return value: #CoglXlibFilterReturn. %COGL_XLIB_FILTER_REMOVE
- * indicates that Cogl has internally handled the event and the
- * caller should do no further processing. %COGL_XLIB_FILTER_CONTINUE
- * indicates that Cogl is either not interested in the event,
- * or has used the event to update internal state without taking
- * any exclusive action.
- *
- * Stability: Unstable
- * Deprecated: 1.16: Use cogl_xlib_renderer_handle_event() instead
- */
-COGL_DEPRECATED_FOR (cogl_xlib_renderer_handle_event)
-CoglFilterReturn
-cogl_xlib_handle_event (XEvent *xevent);
-
-G_END_DECLS
-
-
 /* The gobject introspection scanner seems to parse public headers in
  * isolation which means we need to be extra careful about how we
  * define and undefine __COGL_H_INSIDE__ used to detect when internal


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