diff options
author | Matthias Clasen <mclasen@redhat.com> | 2006-06-17 05:15:49 +0000 |
---|---|---|
committer | Matthias Clasen <matthiasc@src.gnome.org> | 2006-06-17 05:15:49 +0000 |
commit | 9ee7d66fa3b127769a15545efb042efe32bc5591 (patch) | |
tree | 4ba49e5e2a2e73677da0cc6cb6252ae2e3f1c7d6 /gtk/gtkprinteroptionwidget.c | |
parent | 320660fb8100271f4abc59a0d86ff02864288dc6 (diff) | |
download | gtk+-9ee7d66fa3b127769a15545efb042efe32bc5591.tar.gz |
~
2006-06-17 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintunixdialog.c: Clean up the handling of
printer-specific options. There is just one extension point on the
main tab now, and all options in the GtkPrintDialogExtension
group are put there.
Diffstat (limited to 'gtk/gtkprinteroptionwidget.c')
-rw-r--r-- | gtk/gtkprinteroptionwidget.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/gtk/gtkprinteroptionwidget.c b/gtk/gtkprinteroptionwidget.c index 627fe541ab..2b5941164f 100644 --- a/gtk/gtkprinteroptionwidget.c +++ b/gtk/gtkprinteroptionwidget.c @@ -490,22 +490,22 @@ radio_changed_cb (GtkWidget *button, } static void -alternative_set (GtkWidget *box, - const gchar *value) +select_maybe (GtkWidget *widget, + const gchar *value) { - GList *children, *l; - - children = gtk_container_get_children (GTK_CONTAINER (box)); - - for (l = children; l != NULL; l = l->next) - { - char *v = g_object_get_data (G_OBJECT (l->data), "value"); + char *v = g_object_get_data (G_OBJECT (widget), "value"); - if (strcmp (value, v) == 0) - gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (l->data), TRUE); - } + if (strcmp (value, v) == 0) + gtk_toggle_button_set_active (GTK_TOGGLE_BUTTON (widget), TRUE); +} - g_list_free (children); +static void +alternative_set (GtkWidget *box, + const gchar *value) +{ + gtk_container_foreach (GTK_CONTAINER (box), + (GtkCallback) select_maybe, + value); } static GSList * |