summaryrefslogtreecommitdiff
path: root/gst/gstindexfactory.c
diff options
context:
space:
mode:
authorSebastian Dröge <sebastian.droege@collabora.co.uk>2009-04-04 10:20:36 +0200
committerSebastian Dröge <sebastian.droege@collabora.co.uk>2009-04-04 10:20:36 +0200
commite7ccf786c39954724c7fd8eb84fff4c960703cf9 (patch)
tree4737c0dbbdce8fc398bd6b42698748fd95e3a945 /gst/gstindexfactory.c
parent42febffe0d53aa7aa06f3ee35b54a54969b34718 (diff)
gst: Use G_DEFINE_TYPE and friends or at least g_once_init_* in the _get_type() functions
Diffstat (limited to 'gst/gstindexfactory.c')
-rw-r--r--gst/gstindexfactory.c35
1 files changed, 7 insertions, 28 deletions
diff --git a/gst/gstindexfactory.c b/gst/gstindexfactory.c
index 7dfecbe515..1e91ed1936 100644
--- a/gst/gstindexfactory.c
+++ b/gst/gstindexfactory.c
@@ -43,38 +43,12 @@ static void gst_index_factory_finalize (GObject * object);
static GstPluginFeatureClass *factory_parent_class = NULL;
/* static guint gst_index_factory_signals[LAST_SIGNAL] = { 0 }; */
-
-GType
-gst_index_factory_get_type (void)
-{
- static GType indexfactory_type = 0;
-
- if (G_UNLIKELY (indexfactory_type == 0)) {
- static const GTypeInfo indexfactory_info = {
- sizeof (GstIndexFactoryClass),
- NULL,
- NULL,
- (GClassInitFunc) gst_index_factory_class_init,
- NULL,
- NULL,
- sizeof (GstIndexFactory),
- 0,
- NULL,
- NULL
- };
-
- indexfactory_type = g_type_register_static (GST_TYPE_PLUGIN_FEATURE,
- "GstIndexFactory", &indexfactory_info, 0);
- }
- return indexfactory_type;
-}
+G_DEFINE_TYPE (GstIndexFactory, gst_index_factory, GST_TYPE_PLUGIN_FEATURE);
static void
gst_index_factory_class_init (GstIndexFactoryClass * klass)
{
- GObjectClass *gobject_class;
-
- gobject_class = (GObjectClass *) klass;
+ GObjectClass *gobject_class = (GObjectClass *) klass;
factory_parent_class = g_type_class_peek_parent (klass);
@@ -82,6 +56,11 @@ gst_index_factory_class_init (GstIndexFactoryClass * klass)
}
static void
+gst_index_factory_init (GstIndexFactory * factory)
+{
+}
+
+static void
gst_index_factory_finalize (GObject * object)
{
GstIndexFactory *factory = GST_INDEX_FACTORY (object);