projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Scatterplot Dialog: fix spacing
[pspp]
/
src
/
ui
/
gui
/
psppire-dialog-action-regression.c
diff --git
a/src/ui/gui/psppire-dialog-action-regression.c
b/src/ui/gui/psppire-dialog-action-regression.c
index 7a09132093505321fcf1819f24132ffdc0a04096..fd168c435057c401f0bf36410b285d3fdbfe5440 100644
(file)
--- a/
src/ui/gui/psppire-dialog-action-regression.c
+++ b/
src/ui/gui/psppire-dialog-action-regression.c
@@
-147,7
+147,14
@@
psppire_dialog_action_regression_activate (GtkAction *a)
PsppireDialogActionRegression *act = PSPPIRE_DIALOG_ACTION_REGRESSION (a);
PsppireDialogAction *pda = PSPPIRE_DIALOG_ACTION (a);
PsppireDialogActionRegression *act = PSPPIRE_DIALOG_ACTION_REGRESSION (a);
PsppireDialogAction *pda = PSPPIRE_DIALOG_ACTION (a);
- GtkBuilder *xml = builder_new ("regression.ui");
+ GHashTable *thing = psppire_dialog_action_get_pointer (pda);
+ GtkBuilder *xml = g_hash_table_lookup (thing, a);
+ if (!xml)
+ {
+ xml = builder_new ("regression.ui");
+ g_hash_table_insert (thing, a, xml);
+ }
+
GtkWidget *stat_button = get_widget_assert (xml, "stat-button");
GtkWidget *save_button = get_widget_assert (xml, "save-button");
GtkWidget *stat_button = get_widget_assert (xml, "stat-button");
GtkWidget *save_button = get_widget_assert (xml, "save-button");
@@
-162,8
+169,6
@@
psppire_dialog_action_regression_activate (GtkAction *a)
act->pred_button = get_widget_assert (xml, "pred-button");
act->resid_button = get_widget_assert (xml, "resid-button");
act->pred_button = get_widget_assert (xml, "pred-button");
act->resid_button = get_widget_assert (xml, "resid-button");
- g_object_unref (xml);
-
psppire_checkbox_treeview_populate (PSPPIRE_CHECKBOX_TREEVIEW (act->stat_view),
B_RG_STATS_DEFAULT,
N_REGRESSION_STATS,
psppire_checkbox_treeview_populate (PSPPIRE_CHECKBOX_TREEVIEW (act->stat_view),
B_RG_STATS_DEFAULT,
N_REGRESSION_STATS,
@@
-205,9
+210,10
@@
generate_syntax (PsppireDialogAction *a)
g_string_append (string, "\n\t/VARIABLES=");
psppire_var_view_append_names (PSPPIRE_VAR_VIEW (rd->indep_vars), 0, string);
g_string_append (string, "\n\t/VARIABLES=");
psppire_var_view_append_names (PSPPIRE_VAR_VIEW (rd->indep_vars), 0, string);
- g_string_append (string, "\n\t/DEPENDENT=
\t
");
+ g_string_append (string, "\n\t/DEPENDENT=");
psppire_var_view_append_names (PSPPIRE_VAR_VIEW (rd->dep_vars), 0, string);
psppire_var_view_append_names (PSPPIRE_VAR_VIEW (rd->dep_vars), 0, string);
-
+ g_string_append (string, "\n\t/METHOD=ENTER");
+
selected = 0;
for (i = 0, ok = gtk_tree_model_get_iter_first (model, &iter); ok;
i++, ok = gtk_tree_model_iter_next (model, &iter))
selected = 0;
for (i = 0, ok = gtk_tree_model_get_iter_first (model, &iter); ok;
i++, ok = gtk_tree_model_iter_next (model, &iter))
@@
-255,9
+261,7
@@
generate_syntax (PsppireDialogAction *a)
static void
psppire_dialog_action_regression_class_init (PsppireDialogActionRegressionClass *class)
{
static void
psppire_dialog_action_regression_class_init (PsppireDialogActionRegressionClass *class)
{
- GtkActionClass *action_class = GTK_ACTION_CLASS (class);
-
- action_class->activate = psppire_dialog_action_regression_activate;
+ psppire_dialog_action_set_activation (class, psppire_dialog_action_regression_activate);
PSPPIRE_DIALOG_ACTION_CLASS (class)->generate_syntax = generate_syntax;
}
PSPPIRE_DIALOG_ACTION_CLASS (class)->generate_syntax = generate_syntax;
}