window: reset edit dialog's event on response

Currently, we keep the to-be-edited event of the Edit
dialog when it sends any response. However, this can
cause issues since we can edit the event, press Esc and
see that the event didn't change but Edit dialog keeps
the changes.

Fix that by always resetting the edited event to NULL
after a response.

https://bugzilla.gnome.org/show_bug.cgi?id=778644
This commit is contained in:
Georges Basile Stavracas Neto
2017-02-20 08:29:59 -03:00
parent 26aec12762
commit aa9b83a92e
+1
View File
@@ -1131,6 +1131,7 @@ edit_dialog_closed (GtkDialog *dialog,
event = gcal_edit_dialog_get_event (edit_dialog);
view = GCAL_VIEW (window->views[window->active_view]);
gcal_edit_dialog_set_event (edit_dialog, NULL);
gtk_widget_hide (GTK_WIDGET (dialog));
switch (response)