projects
/
pspp
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix crash when attempting to add a new variable in the middle of the dictionary.
[pspp]
/
src
/
ui
/
gui
/
psppire-dialog-action-oneway.c
diff --git
a/src/ui/gui/psppire-dialog-action-oneway.c
b/src/ui/gui/psppire-dialog-action-oneway.c
index 604c271f57e2e7af36cf3aff22c71d7adc28ab53..77512977a9049f230bd393be8d108bb99da4566d 100644
(file)
--- a/
src/ui/gui/psppire-dialog-action-oneway.c
+++ b/
src/ui/gui/psppire-dialog-action-oneway.c
@@
-47,7
+47,7
@@
G_DEFINE_TYPE (PsppireDialogActionOneway, psppire_dialog_action_oneway, PSPPIRE_
static char *
static char *
-generate_syntax (PsppireDialogAction *act)
+generate_syntax (
const
PsppireDialogAction *act)
{
PsppireDialogActionOneway *ow = PSPPIRE_DIALOG_ACTION_ONEWAY (act);
gchar *text;
{
PsppireDialogActionOneway *ow = PSPPIRE_DIALOG_ACTION_ONEWAY (act);
gchar *text;
@@
-218,21
+218,13
@@
clone_contrasts_array (GArray *src_array)
}
}
-
-
-static void
-psppire_dialog_action_oneway_activate (GtkAction *a)
+static GtkBuilder *
+psppire_dialog_action_oneway_activate (PsppireDialogAction *a, GVariant *param)
{
PsppireDialogAction *pda = PSPPIRE_DIALOG_ACTION (a);
PsppireDialogActionOneway *act = PSPPIRE_DIALOG_ACTION_ONEWAY (a);
{
PsppireDialogAction *pda = PSPPIRE_DIALOG_ACTION (a);
PsppireDialogActionOneway *act = PSPPIRE_DIALOG_ACTION_ONEWAY (a);
- GHashTable *thing = psppire_dialog_action_get_pointer (pda);
- GtkBuilder *xml = g_hash_table_lookup (thing, a);
- if (!xml)
- {
- xml = builder_new ("oneway.ui");
- g_hash_table_insert (thing, a, xml);
- }
+ GtkBuilder *xml = builder_new ( "oneway.ui");
GtkWidget *contrasts_button =
get_widget_assert (xml, "contrasts-button");
GtkWidget *contrasts_button =
get_widget_assert (xml, "contrasts-button");
@@
-248,7
+240,7
@@
psppire_dialog_action_oneway_activate (GtkAction *a)
act->homogeneity = get_widget_assert (xml, "checkbutton2");
act->contrasts_dialog = get_widget_assert (xml, "contrasts-dialog");
act->homogeneity = get_widget_assert (xml, "checkbutton2");
act->contrasts_dialog = get_widget_assert (xml, "contrasts-dialog");
-
+
act->next = get_widget_assert (xml, "next-button");
act->prev = get_widget_assert (xml, "prev-button");
act->ctotal = get_widget_assert (xml, "entry2");
act->next = get_widget_assert (xml, "next-button");
act->prev = get_widget_assert (xml, "prev-button");
act->ctotal = get_widget_assert (xml, "entry2");
@@
-272,15
+264,13
@@
psppire_dialog_action_oneway_activate (GtkAction *a)
psppire_dialog_action_set_valid_predicate (pda, dialog_state_valid);
psppire_dialog_action_set_refresh (pda, refresh);
psppire_dialog_action_set_valid_predicate (pda, dialog_state_valid);
psppire_dialog_action_set_refresh (pda, refresh);
-
- if (PSPPIRE_DIALOG_ACTION_CLASS (psppire_dialog_action_oneway_parent_class)->activate)
- PSPPIRE_DIALOG_ACTION_CLASS (psppire_dialog_action_oneway_parent_class)->activate (pda);
+ return xml;
}
static void
psppire_dialog_action_oneway_class_init (PsppireDialogActionOnewayClass *class)
{
}
static void
psppire_dialog_action_oneway_class_init (PsppireDialogActionOnewayClass *class)
{
-
psppire_dialog_action_set_activation (class, psppire_dialog_action_oneway_activate)
;
+
PSPPIRE_DIALOG_ACTION_CLASS (class)->initial_activate = psppire_dialog_action_oneway_activate
;
PSPPIRE_DIALOG_ACTION_CLASS (class)->generate_syntax = generate_syntax;
}
PSPPIRE_DIALOG_ACTION_CLASS (class)->generate_syntax = generate_syntax;
}