[gnome-online-accounts/wip/rishi/port-to-g-declare: 4/7] media-server: Use G_DECLARE_FINAL_TYPE



commit 47871cca6263d78ab31a1ac997130a911eb9c939
Author: Debarshi Ray <debarshir gnome org>
Date:   Thu Dec 5 18:44:20 2019 +0100

    media-server: Use G_DECLARE_FINAL_TYPE

 src/goabackend/goamediaserverprovider.c | 8 --------
 src/goabackend/goamediaserverprovider.h | 9 +++------
 2 files changed, 3 insertions(+), 14 deletions(-)
---
diff --git a/src/goabackend/goamediaserverprovider.c b/src/goabackend/goamediaserverprovider.c
index 95b58f9e..9ffd2a06 100644
--- a/src/goabackend/goamediaserverprovider.c
+++ b/src/goabackend/goamediaserverprovider.c
@@ -22,7 +22,6 @@
 #include "goaprovider.h"
 #include "goaobjectskeletonutils.h"
 #include "goautils.h"
-#include "goaprovider-priv.h"
 #include "goamediaserverprovider.h"
 #include "goadleynaservermanager.h"
 #include "goadleynaservermediadevice.h"
@@ -34,13 +33,6 @@ struct _GoaMediaServerProvider
   GoaDlnaServerManager *dlna_mngr;
 };
 
-typedef struct _GoaMediaServerProviderClass GoaMediaServerProviderClass;
-
-struct _GoaMediaServerProviderClass
-{
-  GoaProviderClass parent_class;
-};
-
 G_DEFINE_TYPE_WITH_CODE (GoaMediaServerProvider, goa_media_server_provider, GOA_TYPE_PROVIDER,
                          goa_provider_ensure_extension_points_registered ();
                          g_io_extension_point_implement (GOA_PROVIDER_EXTENSION_POINT_NAME,
diff --git a/src/goabackend/goamediaserverprovider.h b/src/goabackend/goamediaserverprovider.h
index f473ae1c..e6b36870 100644
--- a/src/goabackend/goamediaserverprovider.h
+++ b/src/goabackend/goamediaserverprovider.h
@@ -25,15 +25,12 @@
 
 #include <glib-object.h>
 
+#include "goaprovider-priv.h"
+
 G_BEGIN_DECLS
 
 #define GOA_TYPE_MEDIA_SERVER_PROVIDER   (goa_media_server_provider_get_type ())
-#define GOA_MEDIA_SERVER_PROVIDER(o)     (G_TYPE_CHECK_INSTANCE_CAST ((o), GOA_TYPE_MEDIA_SERVER_PROVIDER, 
GoaMediaServerProvider))
-#define GOA_IS_MEDIA_SERVER_PROVIDER(o)  (G_TYPE_CHECK_INSTANCE_TYPE ((o), GOA_TYPE_MEDIA_SERVER_PROVIDER))
-
-typedef struct _GoaMediaServerProvider GoaMediaServerProvider;
-
-GType goa_media_server_provider_get_type (void) G_GNUC_CONST;
+G_DECLARE_FINAL_TYPE (GoaMediaServerProvider, goa_media_server_provider, GOA, MEDIA_SERVER_PROVIDER, 
GoaProvider);
 
 G_END_DECLS
 


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