backends/x11: Make the X11 backend derivable

Make the X11 backend derivable so that we can base a nested test backend
on it.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
This commit is contained in:
Jonas Ådahl 2016-12-05 18:33:19 +08:00
parent d3920ddb67
commit d188949101
3 changed files with 9 additions and 7 deletions

View File

@ -278,6 +278,8 @@ struct _MetaOutputInfo {
#define META_IS_MONITOR_MANAGER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), META_TYPE_MONITOR_MANAGER))
#define META_MONITOR_MANAGER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), META_TYPE_MONITOR_MANAGER, MetaMonitorManagerClass))
G_DEFINE_AUTOPTR_CLEANUP_FUNC (MetaMonitorManager, g_object_unref)
struct _MetaMonitorManager
{
MetaDBusDisplayConfigSkeleton parent_instance;

View File

@ -55,11 +55,6 @@
#include "display-private.h"
#include "compositor/compositor-private.h"
struct _MetaBackendX11
{
MetaBackend parent;
};
typedef enum {
/* We're a traditional CM running under the host. */
META_BACKEND_X11_MODE_COMPOSITOR,

View File

@ -32,8 +32,13 @@
#include "backends/x11/meta-clutter-backend-x11.h"
#define META_TYPE_BACKEND_X11 (meta_backend_x11_get_type ())
G_DECLARE_FINAL_TYPE (MetaBackendX11, meta_backend_x11,
META, BACKEND_X11, MetaBackend)
G_DECLARE_DERIVABLE_TYPE (MetaBackendX11, meta_backend_x11,
META, BACKEND_X11, MetaBackend)
struct _MetaBackendX11Class
{
MetaBackendClass parent_class;
};
Display * meta_backend_x11_get_xdisplay (MetaBackendX11 *backend);