summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlejandro Piñeiro <apinheiro@igalia.com>2019-02-19 16:46:16 +0100
committerAlejandro Piñeiro <apinheiro@igalia.com>2019-03-09 11:58:15 +0100
commit04f7696a203d74e10d310fa935ff7d8d8b64d913 (patch)
treefd034ae16b7fec9897d83b073b12c765a5b96521
parent5bd749872b2113134b2b9ef527546c276e2b9855 (diff)
downloadatk-04f7696a203d74e10d310fa935ff7d8d8b64d913.tar.gz
Revert "atkimplementor: use the G_DEFINE_INTERFACE macro to declare it as interface in the introspection"
This reverts commit 30f2712c5bbffbc03e98272c852d29b4bdf8b52e. Fixes https://gitlab.gnome.org/GNOME/atk/issues/1
-rw-r--r--atk/atkobject.c22
-rw-r--r--atk/atkobject.h2
2 files changed, 18 insertions, 6 deletions
diff --git a/atk/atkobject.c b/atk/atkobject.c
index f8e855e..d50be54 100644
--- a/atk/atkobject.c
+++ b/atk/atkobject.c
@@ -57,9 +57,6 @@
*
*/
-typedef AtkImplementorIface AtkImplementorInterface;
-G_DEFINE_INTERFACE (AtkImplementor, atk_implementor, G_TYPE_OBJECT)
-
static GPtrArray *role_names = NULL;
enum
@@ -680,9 +677,24 @@ atk_object_init (AtkObject *accessible,
accessible->role = ATK_ROLE_UNKNOWN;
}
-static void
-atk_implementor_default_init (AtkImplementorInterface *iface)
+GType
+atk_implementor_get_type (void)
{
+ static GType type = 0;
+
+ if (!type)
+ {
+ static const GTypeInfo typeInfo =
+ {
+ sizeof (AtkImplementorIface),
+ (GBaseInitFunc) NULL,
+ (GBaseFinalizeFunc) NULL,
+ } ;
+
+ type = g_type_register_static (G_TYPE_INTERFACE, "AtkImplementorIface", &typeInfo, 0) ;
+ }
+
+ return type;
}
/**
diff --git a/atk/atkobject.h b/atk/atkobject.h
index 4cb8ce2..711dda7 100644
--- a/atk/atkobject.h
+++ b/atk/atkobject.h
@@ -678,7 +678,7 @@ struct _AtkImplementorIface
};
ATK_AVAILABLE_IN_ALL
-GType atk_implementor_get_type (void) G_GNUC_CONST;
+GType atk_implementor_get_type (void);
ATK_AVAILABLE_IN_ALL
AtkObject* atk_implementor_ref_accessible (AtkImplementor *implementor);