gio: Use the new private instance data declaration

Use the newly added macros, and remove the explicit calls to
g_type_class_add_private().

https://bugzilla.gnome.org/show_bug.cgi?id=700035
This commit is contained in:
Emmanuele Bassi
2013-06-11 00:29:58 +01:00
parent aba80eea6c
commit 32747def4b
76 changed files with 387 additions and 730 deletions

View File

@@ -65,13 +65,12 @@ struct _GTlsPasswordPrivate
gchar *warning;
};
G_DEFINE_TYPE (GTlsPassword, g_tls_password, G_TYPE_OBJECT);
G_DEFINE_TYPE_WITH_PRIVATE (GTlsPassword, g_tls_password, G_TYPE_OBJECT)
static void
g_tls_password_init (GTlsPassword *password)
{
password->priv = G_TYPE_INSTANCE_GET_PRIVATE (password, G_TYPE_TLS_PASSWORD,
GTlsPasswordPrivate);
password->priv = g_tls_password_get_private (password);
}
static const guchar *
@@ -195,8 +194,6 @@ g_tls_password_class_init (GTlsPasswordClass *klass)
gobject_class->set_property = g_tls_password_set_property;
gobject_class->finalize = g_tls_password_finalize;
g_type_class_add_private (klass, sizeof (GTlsPasswordPrivate));
g_object_class_install_property (gobject_class, PROP_FLAGS,
g_param_spec_flags ("flags",
P_("Flags"),