diff --git a/src/gui/gcal-window.c b/src/gui/gcal-window.c index cc13e5aa..60e6cc91 100644 --- a/src/gui/gcal-window.c +++ b/src/gui/gcal-window.c @@ -526,6 +526,15 @@ switch_prev_view (GcalWindow *self) * Callbacks */ +static void +event_editor_closed_cb (GcalEventEditorDialog *dialog, + GcalWindow *self) +{ + g_assert (GCAL_IS_WINDOW (self)); + + focus_last_focused_widget (self); +} + static void on_show_calendars_action_activated (GSimpleAction *action, GVariant *param, @@ -1494,6 +1503,7 @@ gcal_window_init (GcalWindow *self) G_N_ELEMENTS(drop_types)); gcal_drop_overlay_set_drop_target(self->drop_overlay, self->drop_target); + g_signal_connect_object (self->event_editor, "closed", G_CALLBACK (event_editor_closed_cb), self, 0); } /**