diff --git a/ChangeLog b/ChangeLog index ff49ca66ec..abb92ae960 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2006-04-26 Joshua Sled + + * src/gnome/dialog-scheduledxaction.c + (scheduledxaction_editor_dialog_destroy): re-order SX disolution + vs. ui teardown. Add comment info-request response. + 2006-04-26 Christian Stimming * doc/gnucash.1.in: Properly quote marks. Bug #339731. diff --git a/src/gnome/dialog-scheduledxaction.c b/src/gnome/dialog-scheduledxaction.c index 77c93b0d0a..0cac6793eb 100644 --- a/src/gnome/dialog-scheduledxaction.c +++ b/src/gnome/dialog-scheduledxaction.c @@ -1163,12 +1163,6 @@ scheduledxaction_editor_dialog_destroy(GtkObject *object, gpointer data) gnc_unregister_gui_component_by_data (DIALOG_SCHEDXACTION_EDITOR_CM_CLASS, sxed); - if ( sxed->newsxP ) { - /* FIXME: WTF??? */ - xaccSchedXactionFree( sxed->sx ); - } - sxed->sx = NULL; - gnc_embedded_window_close_page(sxed->embed_window, sxed->plugin_page); gtk_widget_destroy(GTK_WIDGET(sxed->embed_window)); sxed->embed_window = NULL; @@ -1183,6 +1177,19 @@ scheduledxaction_editor_dialog_destroy(GtkObject *object, gpointer data) } g_free( sxed->cal_marks ); + if ( sxed->newsxP ) { + /* FIXME: WTF??? + * + * "WTF" explaination: in the "new" click from the caller, we + * set this flag. When "ok" is pressed on the dialog, we set + * this flag to false, and thus leave the SX live. If + * "Cancel" is clicked, the flag will still be true, and this + * SX will be cleaned, here. -- jsled + */ + xaccSchedXactionFree( sxed->sx ); + } + sxed->sx = NULL; + g_free (sxed); }