diff options
author | Jasper St. Pierre <jstpierre@mecheye.net> | 2014-06-26 18:22:42 -0400 |
---|---|---|
committer | Jasper St. Pierre <jstpierre@mecheye.net> | 2014-06-26 19:06:43 -0400 |
commit | 9c37b3de7466a22d4c784657a86c522e2a4f118a (patch) | |
tree | 8efe1f75cef57d9af8484324dca0c35714a1ca16 /gtk/gtkcustompaperunixdialog.c | |
parent | 66492678b5a3043f4acd77a6a41405bc4f8097b3 (diff) | |
download | gtk+-9c37b3de7466a22d4c784657a86c522e2a4f118a.tar.gz |
gtk: Don't use GObjectClass.constructor
Use the newer constructed instead, which has a fast path in GObject.
Diffstat (limited to 'gtk/gtkcustompaperunixdialog.c')
-rw-r--r-- | gtk/gtkcustompaperunixdialog.c | 17 |
1 files changed, 5 insertions, 12 deletions
diff --git a/gtk/gtkcustompaperunixdialog.c b/gtk/gtkcustompaperunixdialog.c index 8dd43b798a..b98ba78abd 100644 --- a/gtk/gtkcustompaperunixdialog.c +++ b/gtk/gtkcustompaperunixdialog.c @@ -90,9 +90,7 @@ enum { G_DEFINE_TYPE_WITH_PRIVATE (GtkCustomPaperUnixDialog, gtk_custom_paper_unix_dialog, GTK_TYPE_DIALOG) -static GObject *gtk_custom_paper_unix_dialog_constructor (GType type, - guint n_params, - GObjectConstructParam *params); +static void gtk_custom_paper_unix_dialog_constructed (GObject *object); static void gtk_custom_paper_unix_dialog_finalize (GObject *object); static void populate_dialog (GtkCustomPaperUnixDialog *dialog); static void printer_added_cb (GtkPrintBackend *backend, @@ -273,7 +271,7 @@ _gtk_print_save_custom_papers (GtkListStore *store) static void gtk_custom_paper_unix_dialog_class_init (GtkCustomPaperUnixDialogClass *class) { - G_OBJECT_CLASS (class)->constructor = gtk_custom_paper_unix_dialog_constructor; + G_OBJECT_CLASS (class)->constructed = gtk_custom_paper_unix_dialog_constructed; G_OBJECT_CLASS (class)->finalize = gtk_custom_paper_unix_dialog_finalize; } @@ -317,15 +315,12 @@ gtk_custom_paper_unix_dialog_init (GtkCustomPaperUnixDialog *dialog) g_signal_connect (dialog, "response", G_CALLBACK (custom_paper_dialog_response_cb), NULL); } -static GObject * -gtk_custom_paper_unix_dialog_constructor (GType type, - guint n_params, - GObjectConstructParam *params) +static void +gtk_custom_paper_unix_dialog_constructed (GObject *object) { - GObject *object; gboolean use_header; - object = G_OBJECT_CLASS (gtk_custom_paper_unix_dialog_parent_class)->constructor (type, n_params, params); + G_OBJECT_CLASS (gtk_custom_paper_unix_dialog_parent_class)->constructed (object); g_object_get (object, "use-header-bar", &use_header, NULL); if (!use_header) @@ -335,8 +330,6 @@ gtk_custom_paper_unix_dialog_constructor (GType type, NULL); gtk_dialog_set_default_response (GTK_DIALOG (object), GTK_RESPONSE_CLOSE); } - - return object; } static void |