Remove meta_get_backend()

It should be retrieved from the context via an ownership chain.

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/2718>
This commit is contained in:
Jonas Ådahl 2022-05-29 00:09:33 +02:00 committed by Robert Mader
parent aa2a663380
commit 2340af8d93
2 changed files with 0 additions and 21 deletions

View File

@ -116,23 +116,8 @@ enum
static guint signals[N_SIGNALS];
static MetaBackend *_backend;
#define HIDDEN_POINTER_TIMEOUT 300 /* ms */
/**
* meta_get_backend:
*
* Accessor for the singleton MetaBackend.
*
* Returns: (transfer none): The only #MetaBackend there is.
*/
MetaBackend *
meta_get_backend (void)
{
return _backend;
}
struct _MetaBackendPrivate
{
MetaContext *context;
@ -213,8 +198,6 @@ meta_backend_dispose (GObject *object)
MetaBackend *backend = META_BACKEND (object);
MetaBackendPrivate *priv = meta_backend_get_instance_private (backend);
_backend = NULL;
g_clear_pointer (&priv->cursor_tracker, meta_cursor_tracker_destroy);
g_clear_object (&priv->current_device);
g_clear_object (&priv->color_manager);
@ -1236,7 +1219,6 @@ initable_iface_init (GInitableIface *initable_iface)
static void
meta_backend_init (MetaBackend *backend)
{
_backend = backend;
}
/**

View File

@ -43,9 +43,6 @@ typedef enum _MetaBackendCapabilities
META_EXPORT
G_DECLARE_DERIVABLE_TYPE (MetaBackend, meta_backend, META, BACKEND, GObject)
META_EXPORT
MetaBackend * meta_get_backend (void);
META_EXPORT
void meta_backend_set_keymap (MetaBackend *backend,
const char *layouts,