summaryrefslogtreecommitdiff
path: root/gtk/gtkpagesetupunixdialog.c
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2020-07-04 21:47:48 +0200
committerBenjamin Otte <otte@redhat.com>2020-07-05 02:59:21 +0200
commit508073072822b83dccf3bc5aa642f488c967de52 (patch)
tree1ab4dd2aaab1ae3a7d1a4485f5dc4d5e9ef26a48 /gtk/gtkpagesetupunixdialog.c
parentf75a3a0e95b31c84f41acc741d6dfb2028dbe6a2 (diff)
downloadgtk+-508073072822b83dccf3bc5aa642f488c967de52.tar.gz
listmodels: Stop respecting item-type
Simplify all view model APIs and always return G_TYPE_OBJECT as the item-type for every model. It turns out nobody uses item-type anyway. So instead of adding lots of APIs, forcing people to think about it and trying to figure out how to handle filter or map models that modify item types, just having an easy life is a better approach. All the models need to be able to deal with any type of object going through anyway.
Diffstat (limited to 'gtk/gtkpagesetupunixdialog.c')
-rw-r--r--gtk/gtkpagesetupunixdialog.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/gtk/gtkpagesetupunixdialog.c b/gtk/gtkpagesetupunixdialog.c
index 5e2679affd..2e353c0033 100644
--- a/gtk/gtkpagesetupunixdialog.c
+++ b/gtk/gtkpagesetupunixdialog.c
@@ -306,7 +306,7 @@ gtk_page_setup_unix_dialog_init (GtkPageSetupUnixDialog *dialog)
g_list_store_append (store, dialog->page_setup_list);
g_list_store_append (store, dialog->custom_paper_list);
g_list_store_append (store, dialog->manage_papers_list);
- paper_size_list = G_LIST_MODEL (gtk_flatten_list_model_new (GTK_TYPE_PAGE_SETUP, G_LIST_MODEL (store)));
+ 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);
@@ -321,7 +321,7 @@ gtk_page_setup_unix_dialog_init (GtkPageSetupUnixDialog *dialog)
g_list_store_append (printer_list_list, printer_list);
g_object_unref (printer_list);
- full_list = G_LIST_MODEL (gtk_flatten_list_model_new (GTK_TYPE_PRINTER, G_LIST_MODEL (printer_list_list)));
+ full_list = G_LIST_MODEL (gtk_flatten_list_model_new (G_LIST_MODEL (printer_list_list)));
filter = gtk_custom_filter_new (match_func, NULL, NULL);
dialog->printer_list = G_LIST_MODEL (gtk_filter_list_model_new (full_list, filter));