mirror of
https://gitlab.gnome.org/GNOME/libsecret.git
synced 2024-12-22 12:48:51 +00:00
Merge branch 'wip/nielsdg/g-type-private' into 'master'
Remove deprecated g_type_class_add_private() See merge request GNOME/libsecret!14
This commit is contained in:
commit
04d05d9aaf
@ -119,6 +119,7 @@ static void secret_collection_initable_iface (GInitableIface *iface);
|
||||
static void secret_collection_async_initable_iface (GAsyncInitableIface *iface);
|
||||
|
||||
G_DEFINE_TYPE_WITH_CODE (SecretCollection, secret_collection, G_TYPE_DBUS_PROXY,
|
||||
G_ADD_PRIVATE (SecretCollection)
|
||||
G_IMPLEMENT_INTERFACE (G_TYPE_INITABLE, secret_collection_initable_iface);
|
||||
G_IMPLEMENT_INTERFACE (G_TYPE_ASYNC_INITABLE, secret_collection_async_initable_iface);
|
||||
);
|
||||
@ -133,8 +134,7 @@ items_table_new (void)
|
||||
static void
|
||||
secret_collection_init (SecretCollection *self)
|
||||
{
|
||||
self->pv = G_TYPE_INSTANCE_GET_PRIVATE (self, SECRET_TYPE_COLLECTION,
|
||||
SecretCollectionPrivate);
|
||||
self->pv = secret_collection_get_instance_private (self);
|
||||
|
||||
g_mutex_init (&self->pv->mutex);
|
||||
self->pv->cancellable = g_cancellable_new ();
|
||||
@ -503,8 +503,6 @@ secret_collection_class_init (SecretCollectionClass *klass)
|
||||
g_object_class_install_property (gobject_class, PROP_MODIFIED,
|
||||
g_param_spec_uint64 ("modified", "Modified", "Item modified date",
|
||||
0UL, G_MAXUINT64, 0UL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
||||
|
||||
g_type_class_add_private (gobject_class, sizeof (SecretCollectionPrivate));
|
||||
}
|
||||
|
||||
static gboolean
|
||||
|
@ -114,6 +114,7 @@ static void secret_item_initable_iface (GInitableIface *iface);
|
||||
static void secret_item_async_initable_iface (GAsyncInitableIface *iface);
|
||||
|
||||
G_DEFINE_TYPE_WITH_CODE (SecretItem, secret_item, G_TYPE_DBUS_PROXY,
|
||||
G_ADD_PRIVATE (SecretItem)
|
||||
G_IMPLEMENT_INTERFACE (G_TYPE_INITABLE, secret_item_initable_iface);
|
||||
G_IMPLEMENT_INTERFACE (G_TYPE_ASYNC_INITABLE, secret_item_async_initable_iface);
|
||||
);
|
||||
@ -121,7 +122,7 @@ G_DEFINE_TYPE_WITH_CODE (SecretItem, secret_item, G_TYPE_DBUS_PROXY,
|
||||
static void
|
||||
secret_item_init (SecretItem *self)
|
||||
{
|
||||
self->pv = G_TYPE_INSTANCE_GET_PRIVATE (self, SECRET_TYPE_ITEM, SecretItemPrivate);
|
||||
self->pv = secret_item_get_instance_private (self);
|
||||
g_mutex_init (&self->pv->mutex);
|
||||
}
|
||||
|
||||
@ -403,8 +404,6 @@ secret_item_class_init (SecretItemClass *klass)
|
||||
g_object_class_install_property (gobject_class, PROP_MODIFIED,
|
||||
g_param_spec_uint64 ("modified", "Modified", "Item modified date",
|
||||
0UL, G_MAXUINT64, 0UL, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
||||
|
||||
g_type_class_add_private (gobject_class, sizeof (SecretItemPrivate));
|
||||
}
|
||||
|
||||
typedef struct {
|
||||
|
@ -59,19 +59,17 @@ struct _SecretPromptPrivate {
|
||||
gint prompted;
|
||||
};
|
||||
|
||||
G_DEFINE_TYPE (SecretPrompt, secret_prompt, G_TYPE_DBUS_PROXY);
|
||||
G_DEFINE_TYPE_WITH_PRIVATE (SecretPrompt, secret_prompt, G_TYPE_DBUS_PROXY);
|
||||
|
||||
static void
|
||||
secret_prompt_init (SecretPrompt *self)
|
||||
{
|
||||
self->pv = G_TYPE_INSTANCE_GET_PRIVATE (self, SECRET_TYPE_PROMPT,
|
||||
SecretPromptPrivate);
|
||||
self->pv = secret_prompt_get_instance_private (self);
|
||||
}
|
||||
|
||||
static void
|
||||
secret_prompt_class_init (SecretPromptClass *klass)
|
||||
{
|
||||
g_type_class_add_private (klass, sizeof (SecretPromptPrivate));
|
||||
}
|
||||
|
||||
typedef struct {
|
||||
|
@ -140,6 +140,7 @@ static void secret_service_initable_iface (GInitableIface *iface);
|
||||
static void secret_service_async_initable_iface (GAsyncInitableIface *iface);
|
||||
|
||||
G_DEFINE_TYPE_WITH_CODE (SecretService, secret_service, G_TYPE_DBUS_PROXY,
|
||||
G_ADD_PRIVATE (SecretService)
|
||||
G_IMPLEMENT_INTERFACE (G_TYPE_INITABLE, secret_service_initable_iface);
|
||||
G_IMPLEMENT_INTERFACE (G_TYPE_ASYNC_INITABLE, secret_service_async_initable_iface);
|
||||
);
|
||||
@ -225,8 +226,7 @@ service_cache_instance (SecretService *instance)
|
||||
static void
|
||||
secret_service_init (SecretService *self)
|
||||
{
|
||||
self->pv = G_TYPE_INSTANCE_GET_PRIVATE (self, SECRET_TYPE_SERVICE,
|
||||
SecretServicePrivate);
|
||||
self->pv = secret_service_get_instance_private (self);
|
||||
|
||||
g_mutex_init (&self->pv->mutex);
|
||||
self->pv->cancellable = g_cancellable_new ();
|
||||
@ -557,8 +557,6 @@ secret_service_class_init (SecretServiceClass *klass)
|
||||
g_param_spec_boxed ("collections", "Collections", "Secret Service Collections",
|
||||
_secret_list_get_type (), G_PARAM_READABLE | G_PARAM_STATIC_STRINGS));
|
||||
|
||||
g_type_class_add_private (klass, sizeof (SecretServicePrivate));
|
||||
|
||||
/* Initialize this error domain, registers dbus errors */
|
||||
_secret_error_quark = secret_error_get_quark ();
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user