X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fui%2Fgui%2Fpsppire-dialog-action-histogram.c;h=f99000ac2898767180c2663e15971329effe02c2;hb=1039e94d4e7c62e1ff4006bdd77fa04b21314fad;hp=3949886c92fe076b3396695be8bc74b5a3d248df;hpb=e5ed663e9f1998c1c2409a668288d4e5d496beda;p=pspp diff --git a/src/ui/gui/psppire-dialog-action-histogram.c b/src/ui/gui/psppire-dialog-action-histogram.c index 3949886c92..f99000ac28 100644 --- a/src/ui/gui/psppire-dialog-action-histogram.c +++ b/src/ui/gui/psppire-dialog-action-histogram.c @@ -42,7 +42,7 @@ dialog_state_valid (gpointer data) const gchar *var_name = gtk_entry_get_text (GTK_ENTRY (rd->variable)); const struct variable *var = psppire_dict_lookup_var (PSPPIRE_DIALOG_ACTION (rd)->dict, var_name); - if ( var == NULL) + if (var == NULL) return FALSE; @@ -64,11 +64,14 @@ psppire_dialog_action_histogram_activate (PsppireDialogAction *a, GVariant *para PsppireDialogActionHistogram *act = PSPPIRE_DIALOG_ACTION_HISTOGRAM (a); PsppireDialogAction *pda = PSPPIRE_DIALOG_ACTION (a); - GtkBuilder *xml = builder_new ( "histogram.ui"); + GtkBuilder *xml = builder_new ("histogram.ui"); pda->dialog = get_widget_assert (xml, "histogram-dialog"); pda->source = get_widget_assert (xml, "dict-view"); + g_object_set (pda->source, + "predicate", var_is_numeric, NULL); + act->variable = get_widget_assert (xml, "entry1"); act->curve = get_widget_assert (xml, "curve"); @@ -120,4 +123,3 @@ static void psppire_dialog_action_histogram_init (PsppireDialogActionHistogram *act) { } -