1
0
mirror of https://gitlab.gnome.org/GNOME/glib.git synced 2026-10-24 00:49:00 +03:00

gdbusactiongroup: Declare using G_DECLARE_FINAL_TYPE

`GDBusActionGroupClass` was never publicly declared, so the macros
referencing it would never have worked.

Clean that up by moving it all to `G_DECLARE_FINAL_TYPE`, which
postdates when this code was originally written, but which achieves
the same job.

Signed-off-by: Philip Withnall <pwithnall@gnome.org>
Fixes: #3986
This commit is contained in:
Philip Withnall
2026-07-01 18:16:00 +01:00
parent 2156dbf215
commit 118265fb97
3 changed files with 2 additions and 16 deletions

View File

@@ -65,8 +65,6 @@ struct _GDBusActionGroup
gboolean strict;
};
typedef GObjectClass GDBusActionGroupClass;
typedef struct
{
gchar *name;

View File

@@ -31,20 +31,9 @@
G_BEGIN_DECLS
#define G_TYPE_DBUS_ACTION_GROUP (g_dbus_action_group_get_type ())
#define G_DBUS_ACTION_GROUP(inst) (G_TYPE_CHECK_INSTANCE_CAST ((inst), \
G_TYPE_DBUS_ACTION_GROUP, GDBusActionGroup))
#define G_DBUS_ACTION_GROUP_CLASS(class) (G_TYPE_CHECK_CLASS_CAST ((class), \
G_TYPE_DBUS_ACTION_GROUP, GDBusActionGroupClass))
#define G_IS_DBUS_ACTION_GROUP(inst) (G_TYPE_CHECK_INSTANCE_TYPE ((inst), \
G_TYPE_DBUS_ACTION_GROUP))
#define G_IS_DBUS_ACTION_GROUP_CLASS(class) (G_TYPE_CHECK_CLASS_TYPE ((class), \
G_TYPE_DBUS_ACTION_GROUP))
#define G_DBUS_ACTION_GROUP_GET_CLASS(inst) (G_TYPE_INSTANCE_GET_CLASS ((inst), \
G_TYPE_DBUS_ACTION_GROUP, GDBusActionGroupClass))
#define G_TYPE_DBUS_ACTION_GROUP (g_dbus_action_group_get_type ())
GIO_AVAILABLE_IN_ALL
GType g_dbus_action_group_get_type (void);
G_DECLARE_FINAL_TYPE (GDBusActionGroup, g_dbus_action_group, G, DBUS_ACTION_GROUP, GObject)
GIO_AVAILABLE_IN_2_32
GDBusActionGroup * g_dbus_action_group_get (GDBusConnection *connection,

View File

@@ -46,7 +46,6 @@ G_DEFINE_AUTOPTR_CLEANUP_FUNC(GCredentials, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDatagramBased, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDataInputStream, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDataOutputStream, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDBusActionGroup, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDBusAuthObserver, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDBusConnection, g_object_unref)
G_DEFINE_AUTOPTR_CLEANUP_FUNC(GDBusInterface, g_object_unref)