+2007-07-15 John Darrington <john@darrington.wattle.id.au>
+
+ * compute-dialog.c: Only generate NUMERIC/STRING command if the
+ type-and-label dialog was used.
+
2007-07-12 John Darrington <john@darrington.wattle.id.au>
* psppire-data-store.c: Added call to g_sheet_model_range_changed to
{
GladeXML *xml; /* The xml that generated the widgets */
PsppireDict *dict;
+ gboolean use_type;
};
GtkTreeSelection *selection;
-
/* Clear the target variable entry box */
gtk_entry_set_text (GTK_ENTRY (target), "");
g_signal_emit_by_name (target, "changed");
-
/* Clear the syntax area textbuffer */
gtk_text_buffer_get_start_iter (buffer, &start);
gtk_text_buffer_get_end_iter (buffer, &end);
gtk_text_buffer_delete (buffer, &start, &end);
-
/* Unselect all items in the treeview */
selection = gtk_tree_view_get_selection (GTK_TREE_VIEW (varlist));
gtk_tree_selection_unselect_all (selection);
string = g_string_sized_new (64);
- if ( NULL == psppire_dict_lookup_var (cd->dict, target_name ))
+ if ( cd-> use_type &&
+ NULL == psppire_dict_lookup_var (cd->dict, target_name ))
{
if ( gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON (string_toggle)))
{
reset_type_label_dialog (cd);
response = psppire_dialog_run (PSPPIRE_DIALOG (subdialog));
+ if ( response == PSPPIRE_RESPONSE_CONTINUE)
+ cd->use_type = TRUE;
}
vs = PSPPIRE_VAR_STORE (gtk_sheet_get_model (var_sheet));
scd.dict = vs->dict;
+ scd.use_type = FALSE;
g_signal_connect (expression, "toggled",
G_CALLBACK(on_expression_toggle), &scd);