diff options
author | Matthias Clasen <mclasen@redhat.com> | 2020-07-26 10:53:55 -0400 |
---|---|---|
committer | Matthias Clasen <mclasen@redhat.com> | 2020-07-26 14:21:28 -0400 |
commit | 7e87ad188748039d35bca0ecf3630f51e717f174 (patch) | |
tree | b9068cb2ab6d40258fdc267485492a484b35e900 /gtk/gtkprintunixdialog.c | |
parent | ef6babf896cd06bd42d0fb11e3aae7c109708bdd (diff) | |
download | gtk+-flatten-list-constructor.tar.gz |
flattenlistmodel: Make the constructor transfer fullflatten-list-constructor
This is for consistency with other wrapping list constructors.
We want them all to be transfer full, allow-none.
Update all callers.
Diffstat (limited to 'gtk/gtkprintunixdialog.c')
-rw-r--r-- | gtk/gtkprintunixdialog.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/gtk/gtkprintunixdialog.c b/gtk/gtkprintunixdialog.c index 26a25a6cfc..3c88f4cc25 100644 --- a/gtk/gtkprintunixdialog.c +++ b/gtk/gtkprintunixdialog.c @@ -807,7 +807,6 @@ gtk_print_unix_dialog_init (GtkPrintUnixDialog *dialog) g_list_store_append (store, dialog->manage_papers_list); paper_size_list = G_LIST_MODEL (gtk_flatten_list_model_new (G_LIST_MODEL (store))); gtk_drop_down_set_model (GTK_DROP_DOWN (dialog->paper_size_combo), paper_size_list); - g_object_unref (store); g_object_unref (paper_size_list); /* Load backends */ @@ -1037,7 +1036,6 @@ load_print_backends (GtkPrintUnixDialog *dialog) { GList *node; GListStore *lists; - GListModel *model; lists = g_list_store_new (G_TYPE_LIST_MODEL); @@ -1053,11 +1051,7 @@ load_print_backends (GtkPrintUnixDialog *dialog) g_list_store_append (lists, gtk_print_backend_get_printers (backend)); } - model = G_LIST_MODEL (gtk_flatten_list_model_new (G_LIST_MODEL (lists))); - - g_object_unref (lists); - - return model; + return G_LIST_MODEL (gtk_flatten_list_model_new (G_LIST_MODEL (lists))); } static void |