[gnome-photos] widget-shader: Use G_DECLARE_FINAL_TYPE



commit 2c8c043cd3ac5c0c5b3625bbacd0a46022dcfa39
Author: Debarshi Ray <debarshir gnome org>
Date:   Sat Oct 8 09:25:42 2016 +0200

    widget-shader: Use G_DECLARE_FINAL_TYPE
    
    https://bugzilla.gnome.org/show_bug.cgi?id=763712

 src/photos-widget-shader.c |    5 -----
 src/photos-widget-shader.h |   16 ++--------------
 2 files changed, 2 insertions(+), 19 deletions(-)
---
diff --git a/src/photos-widget-shader.c b/src/photos-widget-shader.c
index c605769..ba924fa 100644
--- a/src/photos-widget-shader.c
+++ b/src/photos-widget-shader.c
@@ -34,11 +34,6 @@ struct _PhotosWidgetShader
   gboolean active;
 };
 
-struct _PhotosWidgetShaderClass
-{
-  GInitiallyUnownedClass parent_class;
-};
-
 enum
 {
   PROP_0,
diff --git a/src/photos-widget-shader.h b/src/photos-widget-shader.h
index 0f5391f..1dd0eda 100644
--- a/src/photos-widget-shader.h
+++ b/src/photos-widget-shader.h
@@ -1,6 +1,6 @@
 /*
  * Photos - access, organize and share your photos on GNOME
- * Copyright © 2015 Red Hat, Inc.
+ * Copyright © 2015 – 2016 Red Hat, Inc.
  *
  * This program is free software; you can redistribute it and/or
  * modify it under the terms of the GNU General Public License
@@ -27,19 +27,7 @@
 G_BEGIN_DECLS
 
 #define PHOTOS_TYPE_WIDGET_SHADER (photos_widget_shader_get_type ())
-
-#define PHOTOS_WIDGET_SHADER(obj) \
-  (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
-   PHOTOS_TYPE_WIDGET_SHADER, PhotosWidgetShader))
-
-#define PHOTOS_IS_WIDGET_SHADER(obj) \
-  (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
-   PHOTOS_TYPE_WIDGET_SHADER))
-
-typedef struct _PhotosWidgetShader      PhotosWidgetShader;
-typedef struct _PhotosWidgetShaderClass PhotosWidgetShaderClass;
-
-GType                  photos_widget_shader_get_type               (void) G_GNUC_CONST;
+G_DECLARE_FINAL_TYPE (PhotosWidgetShader, photos_widget_shader, PHOTOS, WIDGET_SHADER, GInitiallyUnowned);
 
 PhotosWidgetShader    *photos_widget_shader_new                    (GtkWidget *widget);
 


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