From 975feb920298ff8defd32432f1fba95c3af9f6d4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20=C3=85dahl?= Date: Fri, 17 Jul 2015 10:46:33 +0800 Subject: [PATCH] MetaCursorRenderer: Use G_DECLARE_DERIVABLE_TYPE to declare the type https://bugzilla.gnome.org/show_bug.cgi?id=744932 --- src/backends/meta-cursor-renderer.h | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/src/backends/meta-cursor-renderer.h b/src/backends/meta-cursor-renderer.h index 7f86835ca..f92b4c706 100644 --- a/src/backends/meta-cursor-renderer.h +++ b/src/backends/meta-cursor-renderer.h @@ -30,20 +30,9 @@ #include #include "meta-cursor.h" -#define META_TYPE_CURSOR_RENDERER (meta_cursor_renderer_get_type ()) -#define META_CURSOR_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), META_TYPE_CURSOR_RENDERER, MetaCursorRenderer)) -#define META_CURSOR_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), META_TYPE_CURSOR_RENDERER, MetaCursorRendererClass)) -#define META_IS_CURSOR_RENDERER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), META_TYPE_CURSOR_RENDERER)) -#define META_IS_CURSOR_RENDERER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), META_TYPE_CURSOR_RENDERER)) -#define META_CURSOR_RENDERER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), META_TYPE_CURSOR_RENDERER, MetaCursorRendererClass)) - -typedef struct _MetaCursorRenderer MetaCursorRenderer; -typedef struct _MetaCursorRendererClass MetaCursorRendererClass; - -struct _MetaCursorRenderer -{ - GObject parent; -}; +#define META_TYPE_CURSOR_RENDERER (meta_cursor_renderer_get_type ()) +G_DECLARE_DERIVABLE_TYPE (MetaCursorRenderer, meta_cursor_renderer, + META, CURSOR_RENDERER, GObject); struct _MetaCursorRendererClass {