[gnome-calendar/gbsneto/edit-dialog-cleanup: 6/23] edit-dialog: Rename to GcalEventEditorDialog




commit b4029b0c236a63042f90abc40ecd9c197b80fdef
Author: Georges Basile Stavracas Neto <georges stavracas gmail com>
Date:   Fri Oct 30 17:38:09 2020 -0300

    edit-dialog: Rename to GcalEventEditorDialog

 src/gui/event-editor/event-editor.gresource.xml    |   2 +-
 src/gui/event-editor/gcal-edit-dialog.h            |  52 ----
 ...al-edit-dialog.c => gcal-event-editor-dialog.c} | 304 ++++++++++-----------
 src/gui/event-editor/gcal-event-editor-dialog.h    |  49 ++++
 ...-edit-dialog.ui => gcal-event-editor-dialog.ui} |  74 ++---
 src/gui/event-editor/meson.build                   |   2 +-
 src/gui/gcal-window.c                              |  48 ++--
 src/gui/gcal-window.ui                             |   2 +-
 8 files changed, 265 insertions(+), 268 deletions(-)
---
diff --git a/src/gui/event-editor/event-editor.gresource.xml b/src/gui/event-editor/event-editor.gresource.xml
index 2c8606f0..9edfba49 100644
--- a/src/gui/event-editor/event-editor.gresource.xml
+++ b/src/gui/event-editor/event-editor.gresource.xml
@@ -4,7 +4,7 @@
     <file compressed="true">gcal-alarm-row.ui</file>
     <file compressed="true">gcal-date-chooser.ui</file>
     <file compressed="true">gcal-date-selector.ui</file>
-    <file compressed="true">gcal-edit-dialog.ui</file>
+    <file compressed="true">gcal-event-editor-dialog.ui</file>
     <file compressed="true">gcal-multi-choice.ui</file>
     <file compressed="true">gcal-time-selector.ui</file>
   </gresource>
diff --git a/src/gui/event-editor/gcal-edit-dialog.c b/src/gui/event-editor/gcal-event-editor-dialog.c
similarity index 81%
rename from src/gui/event-editor/gcal-edit-dialog.c
rename to src/gui/event-editor/gcal-event-editor-dialog.c
index b8577ed9..36f44a4e 100644
--- a/src/gui/event-editor/gcal-edit-dialog.c
+++ b/src/gui/event-editor/gcal-event-editor-dialog.c
@@ -17,13 +17,13 @@
  */
 #include "config.h"
 
-#define G_LOG_DOMAIN "GcalEditDialog"
+#define G_LOG_DOMAIN "GcalEventEditorDialog"
 
 #include "gcal-alarm-row.h"
 #include "gcal-context.h"
 #include "gcal-date-selector.h"
 #include "gcal-debug.h"
-#include "gcal-edit-dialog.h"
+#include "gcal-event-editor-dialog.h"
 #include "gcal-time-selector.h"
 #include "gcal-utils.h"
 #include "gcal-event.h"
@@ -35,17 +35,17 @@
 #include <gtk/gtk.h>
 
 /**
- * SECTION:gcal-edit-dialog
+ * SECTION:gcal-event-editor-dialog
  * @short_description: Event editor dialog
- * @title:GcalEditDialog
- * @image:gcal-edit-dialog.png
+ * @title:GcalEventEditorDialog
+ * @image:gcal-event-editor-dialog.png
  *
- * #GcalEditDialog is the event editor dialog of GNOME Calendar. It
+ * #GcalEventEditorDialog is the event editor dialog of GNOME Calendar. It
  * allows the user to change the various aspects of the events, as
  * well as managing alarms.
  */
 
-struct _GcalEditDialog
+struct _GcalEventEditorDialog
 {
   GtkDialog         parent;
 
@@ -122,18 +122,18 @@ static void          on_calendar_selected_action_cb              (GSimpleAction
                                                                   GVariant           *value,
                                                                   gpointer            user_data);
 
-static void          on_summary_entry_changed_cb                 (GtkEntry           *entry,
-                                                                  GParamSpec         *pspec,
-                                                                  GcalEditDialog     *self);
+static void          on_summary_entry_changed_cb                 (GtkEntry              *entry,
+                                                                  GParamSpec            *pspec,
+                                                                  GcalEventEditorDialog *self);
 
-static void          on_location_entry_changed_cb                (GtkEntry           *entry,
-                                                                  GParamSpec         *pspec,
-                                                                  GcalEditDialog     *self);
+static void          on_location_entry_changed_cb                (GtkEntry              *entry,
+                                                                  GParamSpec            *pspec,
+                                                                  GcalEventEditorDialog *self);
 
-static void          on_add_alarm_button_clicked_cb              (GtkWidget          *button,
-                                                                  GcalEditDialog     *self);
+static void          on_add_alarm_button_clicked_cb              (GtkWidget             *button,
+                                                                  GcalEventEditorDialog *self);
 
-G_DEFINE_TYPE (GcalEditDialog, gcal_edit_dialog, GTK_TYPE_DIALOG)
+G_DEFINE_TYPE (GcalEventEditorDialog, gcal_event_editor_dialog, GTK_TYPE_DIALOG)
 
 enum
 {
@@ -170,7 +170,7 @@ sources_menu_sort_func (gconstpointer a,
 }
 
 static void
-fill_sources_menu (GcalEditDialog *self)
+fill_sources_menu (GcalEventEditorDialog *self)
 {
   g_autoptr (GList) list = NULL;
   GcalManager *manager;
@@ -229,9 +229,9 @@ fill_sources_menu (GcalEditDialog *self)
 }
 
 static void
-find_best_timezones_for_event (GcalEditDialog  *self,
-                               GTimeZone      **out_tz_start,
-                               GTimeZone      **out_tz_end)
+find_best_timezones_for_event (GcalEventEditorDialog  *self,
+                               GTimeZone             **out_tz_start,
+                               GTimeZone             **out_tz_end)
 {
   gboolean was_all_day;
   gboolean all_day;
@@ -292,10 +292,10 @@ find_best_timezones_for_event (GcalEditDialog  *self,
 }
 
 static GDateTime*
-return_datetime_for_widgets (GcalEditDialog   *self,
-                             GTimeZone        *timezone,
-                             GcalDateSelector *date_selector,
-                             GcalTimeSelector *time_selector)
+return_datetime_for_widgets (GcalEventEditorDialog *self,
+                             GTimeZone             *timezone,
+                             GcalDateSelector      *date_selector,
+                             GcalTimeSelector      *time_selector)
 {
   g_autoptr (GDateTime) date_in_local_tz = NULL;
   g_autoptr (GDateTime) date_in_best_tz = NULL;
@@ -332,7 +332,7 @@ return_datetime_for_widgets (GcalEditDialog   *self,
 }
 
 static GDateTime*
-get_date_start (GcalEditDialog *self)
+get_date_start (GcalEventEditorDialog *self)
 {
   g_autoptr (GTimeZone) start_tz = NULL;
 
@@ -345,7 +345,7 @@ get_date_start (GcalEditDialog *self)
 }
 
 static GDateTime*
-get_date_end (GcalEditDialog *self)
+get_date_end (GcalEventEditorDialog *self)
 {
   g_autoptr (GTimeZone) end_tz = NULL;
 
@@ -358,8 +358,8 @@ get_date_end (GcalEditDialog *self)
 }
 
 static void
-set_writable (GcalEditDialog *self,
-              gboolean        writable)
+set_writable (GcalEventEditorDialog *self,
+              gboolean               writable)
 {
   gboolean all_day;
 
@@ -477,7 +477,7 @@ format_datetime_for_display (GDateTime      *date,
 }
 
 static void
-update_date_labels (GcalEditDialog *self)
+update_date_labels (GcalEventEditorDialog *self)
 {
   g_autofree gchar *start_label = NULL;
   g_autofree gchar *end_label = NULL;
@@ -499,9 +499,9 @@ update_date_labels (GcalEditDialog *self)
 }
 
 static void
-sync_datetimes (GcalEditDialog *self,
-                GParamSpec     *pspec,
-                GtkWidget      *widget)
+sync_datetimes (GcalEventEditorDialog *self,
+                GParamSpec            *pspec,
+                GtkWidget             *widget)
 {
   GDateTime *start, *end, *start_local, *end_local, *new_date;
   GtkWidget *date_widget, *time_widget;
@@ -563,7 +563,7 @@ out:
 }
 
 static void
-gcal_edit_dialog_clear_data (GcalEditDialog *self)
+gcal_event_editor_dialog_clear_data (GcalEventEditorDialog *self)
 {
   /* summary */
   g_signal_handlers_block_by_func (self->summary_entry, on_summary_entry_changed_cb, self);
@@ -583,7 +583,7 @@ gcal_edit_dialog_clear_data (GcalEditDialog *self)
   gtk_text_buffer_set_text (gtk_text_view_get_buffer (GTK_TEXT_VIEW (self->notes_text)), "", -1);
 }
 
-#define OFFSET(x)             (G_STRUCT_OFFSET (GcalEditDialog, x))
+#define OFFSET(x)             (G_STRUCT_OFFSET (GcalEventEditorDialog, x))
 #define WIDGET_FROM_OFFSET(x) (G_STRUCT_MEMBER (GtkWidget*, self, x))
 
 struct
@@ -602,8 +602,8 @@ struct
 };
 
 static GtkWidget*
-get_row_for_alarm_trigger_minutes (GcalEditDialog *self,
-                                   gint            minutes)
+get_row_for_alarm_trigger_minutes (GcalEventEditorDialog *self,
+                                   gint                   minutes)
 {
   guint i;
 
@@ -640,7 +640,7 @@ create_alarm (guint minutes)
 }
 
 static void
-clear_alarms (GcalEditDialog *self)
+clear_alarms (GcalEventEditorDialog *self)
 {
   g_autoptr (GList) children = NULL;
   GList *l;
@@ -656,7 +656,7 @@ clear_alarms (GcalEditDialog *self)
 }
 
 static void
-apply_changes_to_event (GcalEditDialog *self)
+apply_changes_to_event (GcalEventEditorDialog *self)
 {
   GcalRecurrenceFrequency freq;
   GcalRecurrence *old_recur;
@@ -799,14 +799,14 @@ on_calendar_selected_action_cb (GSimpleAction *action,
                                 gpointer       user_data)
 {
   g_autoptr (GList) list = NULL;
-  GcalEditDialog *self;
+  GcalEventEditorDialog *self;
   GcalManager *manager;
   GList *aux;
   gchar *uid;
 
   GCAL_ENTRY;
 
-  self = GCAL_EDIT_DIALOG (user_data);
+  self = GCAL_EVENT_EDITOR_DIALOG (user_data);
   manager = gcal_context_get_manager (self->context);
   list = gcal_manager_get_calendars (manager);
 
@@ -843,7 +843,7 @@ on_calendar_selected_action_cb (GSimpleAction *action,
 }
 
 static void
-transient_size_allocate_cb (GcalEditDialog *self)
+transient_size_allocate_cb (GcalEventEditorDialog *self)
 {
   GtkAllocation alloc;
   GtkWindow *transient;
@@ -856,17 +856,17 @@ transient_size_allocate_cb (GcalEditDialog *self)
 }
 
 static void
-on_location_entry_changed_cb (GtkEntry       *entry,
-                              GParamSpec     *pspec,
-                              GcalEditDialog *self)
+on_location_entry_changed_cb (GtkEntry              *entry,
+                              GParamSpec            *pspec,
+                              GcalEventEditorDialog *self)
 {
   gcal_event_set_location (self->event, gtk_entry_get_text (entry));
 }
 
 static void
-on_summary_entry_changed_cb (GtkEntry       *entry,
-                             GParamSpec     *pspec,
-                             GcalEditDialog *self)
+on_summary_entry_changed_cb (GtkEntry              *entry,
+                             GParamSpec            *pspec,
+                             GcalEventEditorDialog *self)
 {
   gtk_widget_set_sensitive (self->done_button, gtk_entry_get_text_length (entry) > 0);
 }
@@ -878,11 +878,11 @@ sort_alarms_func (GtkListBoxRow *a,
 {
   ECalComponentAlarm *alarm_a;
   ECalComponentAlarm *alarm_b;
-  GcalEditDialog *self;
+  GcalEventEditorDialog *self;
   gint minutes_a;
   gint minutes_b;
 
-  self = GCAL_EDIT_DIALOG (user_data);
+  self = GCAL_EVENT_EDITOR_DIALOG (user_data);
 
   if (a == self->new_alarm_row)
     return 1;
@@ -910,11 +910,11 @@ static void
 on_action_button_clicked_cb (GtkWidget *widget,
                              gpointer   user_data)
 {
-  GcalEditDialog *self;
+  GcalEventEditorDialog *self;
 
   GCAL_ENTRY;
 
-  self = GCAL_EDIT_DIALOG (user_data);
+  self = GCAL_EVENT_EDITOR_DIALOG (user_data);
 
   if (widget == self->cancel_button || (widget == self->done_button && !self->writable))
     {
@@ -961,8 +961,8 @@ on_action_button_clicked_cb (GtkWidget *widget,
 }
 
 static void
-on_repeat_duration_changed_cb (GtkComboBox    *widget,
-                               GcalEditDialog *self)
+on_repeat_duration_changed_cb (GtkComboBox           *widget,
+                               GcalEventEditorDialog *self)
 {
   gint active = gtk_combo_box_get_active (widget);
 
@@ -971,8 +971,8 @@ on_repeat_duration_changed_cb (GtkComboBox    *widget,
 }
 
 static void
-on_repeat_type_changed_cb (GtkComboBox    *combobox,
-                           GcalEditDialog *self)
+on_repeat_type_changed_cb (GtkComboBox           *combobox,
+                           GcalEventEditorDialog *self)
 {
   GcalRecurrenceFrequency frequency;
 
@@ -983,9 +983,9 @@ on_repeat_type_changed_cb (GtkComboBox    *combobox,
 }
 
 static void
-on_all_day_switch_active_changed_cb (GtkSwitch      *all_day_switch,
-                                     GParamSpec     *pspec,
-                                     GcalEditDialog *self)
+on_all_day_switch_active_changed_cb (GtkSwitch             *all_day_switch,
+                                     GParamSpec            *pspec,
+                                     GcalEventEditorDialog *self)
 {
   gboolean active = gtk_switch_get_active (all_day_switch);
 
@@ -996,8 +996,8 @@ on_all_day_switch_active_changed_cb (GtkSwitch      *all_day_switch,
 }
 
 static void
-on_remove_alarm_cb (GcalAlarmRow   *alarm_row,
-                    GcalEditDialog *self)
+on_remove_alarm_cb (GcalAlarmRow          *alarm_row,
+                    GcalEventEditorDialog *self)
 {
   ECalComponentAlarm *alarm;
   GtkWidget *alarm_button;
@@ -1035,7 +1035,7 @@ on_remove_alarm_cb (GcalAlarmRow   *alarm_row,
 }
 
 static void
-on_time_format_changed_cb (GcalEditDialog *self)
+on_time_format_changed_cb (GcalEventEditorDialog *self)
 {
   GcalTimeFormat time_format;
 
@@ -1046,8 +1046,8 @@ on_time_format_changed_cb (GcalEditDialog *self)
 }
 
 static GtkWidget *
-create_alarm_row (GcalEditDialog     *self,
-                  ECalComponentAlarm *alarm)
+create_alarm_row (GcalEventEditorDialog *self,
+                  ECalComponentAlarm    *alarm)
 {
   GtkWidget *row;
 
@@ -1058,7 +1058,7 @@ create_alarm_row (GcalEditDialog     *self,
 }
 
 static void
-setup_alarms (GcalEditDialog *self)
+setup_alarms (GcalEventEditorDialog *self)
 {
   g_autoptr (GList) alarms = NULL;
   GList *l;
@@ -1105,8 +1105,8 @@ setup_alarms (GcalEditDialog *self)
 }
 
 static void
-on_add_alarm_button_clicked_cb (GtkWidget      *button,
-                                GcalEditDialog *self)
+on_add_alarm_button_clicked_cb (GtkWidget             *button,
+                                GcalEventEditorDialog *self)
 {
   ECalComponentAlarm *alarm;
   GtkWidget *row;
@@ -1138,9 +1138,9 @@ on_add_alarm_button_clicked_cb (GtkWidget      *button,
 }
 
 static void
-on_alarms_listbox_row_activated_cb (GtkListBox     *alarms_listbox,
-                                    GtkListBoxRow  *row,
-                                    GcalEditDialog *self)
+on_alarms_listbox_row_activated_cb (GtkListBox            *alarms_listbox,
+                                    GtkListBoxRow         *row,
+                                    GcalEventEditorDialog *self)
 {
   if (row == self->new_alarm_row)
     gtk_popover_popup (self->alarms_popover);
@@ -1152,33 +1152,33 @@ on_alarms_listbox_row_activated_cb (GtkListBox     *alarms_listbox,
  */
 
 static void
-gcal_edit_dialog_finalize (GObject *object)
+gcal_event_editor_dialog_finalize (GObject *object)
 {
-  GcalEditDialog *self;
+  GcalEventEditorDialog *self;
 
   GCAL_ENTRY;
 
-  self = GCAL_EDIT_DIALOG (object);
+  self = GCAL_EVENT_EDITOR_DIALOG (object);
 
   g_clear_pointer (&self->alarms, g_ptr_array_unref);
   g_clear_object (&self->action_group);
   g_clear_object (&self->context);
   g_clear_object (&self->event);
 
-  G_OBJECT_CLASS (gcal_edit_dialog_parent_class)->finalize (object);
+  G_OBJECT_CLASS (gcal_event_editor_dialog_parent_class)->finalize (object);
 
   GCAL_EXIT;
 }
 
 static void
-gcal_edit_dialog_constructed (GObject* object)
+gcal_event_editor_dialog_constructed (GObject* object)
 {
-  GcalEditDialog *self;
+  GcalEventEditorDialog *self;
 
-  self = GCAL_EDIT_DIALOG (object);
+  self = GCAL_EVENT_EDITOR_DIALOG (object);
 
   /* chaining up */
-  G_OBJECT_CLASS (gcal_edit_dialog_parent_class)->constructed (object);
+  G_OBJECT_CLASS (gcal_event_editor_dialog_parent_class)->constructed (object);
 
   gtk_window_set_title (GTK_WINDOW (object), "");
 
@@ -1205,12 +1205,12 @@ gcal_edit_dialog_constructed (GObject* object)
 }
 
 static void
-gcal_edit_dialog_get_property (GObject    *object,
-                               guint       prop_id,
-                               GValue     *value,
-                               GParamSpec *pspec)
+gcal_event_editor_dialog_get_property (GObject    *object,
+                                       guint       prop_id,
+                                       GValue     *value,
+                                       GParamSpec *pspec)
 {
-  GcalEditDialog *self = GCAL_EDIT_DIALOG (object);
+  GcalEventEditorDialog *self = GCAL_EVENT_EDITOR_DIALOG (object);
 
   switch (prop_id)
     {
@@ -1232,17 +1232,17 @@ gcal_edit_dialog_get_property (GObject    *object,
 }
 
 static void
-gcal_edit_dialog_set_property (GObject      *object,
-                               guint         prop_id,
-                               const GValue *value,
-                               GParamSpec   *pspec)
+gcal_event_editor_dialog_set_property (GObject      *object,
+                                       guint         prop_id,
+                                       const GValue *value,
+                                       GParamSpec   *pspec)
 {
-  GcalEditDialog *self = GCAL_EDIT_DIALOG (object);
+  GcalEventEditorDialog *self = GCAL_EVENT_EDITOR_DIALOG (object);
 
   switch (prop_id)
     {
     case PROP_EVENT:
-      gcal_edit_dialog_set_event (self, g_value_get_object (value));
+      gcal_event_editor_dialog_set_event (self, g_value_get_object (value));
       break;
 
     case PROP_CONTEXT:
@@ -1266,7 +1266,7 @@ gcal_edit_dialog_set_property (GObject      *object,
 }
 
 static void
-gcal_edit_dialog_class_init (GcalEditDialogClass *klass)
+gcal_event_editor_dialog_class_init (GcalEventEditorDialogClass *klass)
 {
   GObjectClass *object_class = G_OBJECT_CLASS (klass);
   GtkWidgetClass *widget_class = GTK_WIDGET_CLASS (klass);
@@ -1274,13 +1274,13 @@ gcal_edit_dialog_class_init (GcalEditDialogClass *klass)
   g_type_ensure (GCAL_TYPE_DATE_SELECTOR);
   g_type_ensure (GCAL_TYPE_TIME_SELECTOR);
 
-  object_class->finalize = gcal_edit_dialog_finalize;
-  object_class->constructed = gcal_edit_dialog_constructed;
-  object_class->get_property = gcal_edit_dialog_get_property;
-  object_class->set_property = gcal_edit_dialog_set_property;
+  object_class->finalize = gcal_event_editor_dialog_finalize;
+  object_class->constructed = gcal_event_editor_dialog_constructed;
+  object_class->get_property = gcal_event_editor_dialog_get_property;
+  object_class->set_property = gcal_event_editor_dialog_set_property;
 
   /**
-   * GcalEditDialog::event:
+   * GcalEventEditorDialog::event:
    *
    * The #GcalEvent being edited.
    */
@@ -1291,7 +1291,7 @@ gcal_edit_dialog_class_init (GcalEditDialogClass *klass)
                                                 G_PARAM_READWRITE | G_PARAM_EXPLICIT_NOTIFY | 
G_PARAM_STATIC_STRINGS);
 
   /**
-   * GcalEditDialog::manager:
+   * GcalEventEditorDialog::manager:
    *
    * The #GcalManager of the dialog.
    */
@@ -1302,7 +1302,7 @@ gcal_edit_dialog_class_init (GcalEditDialogClass *klass)
                                                   G_PARAM_READWRITE | G_PARAM_EXPLICIT_NOTIFY | 
G_PARAM_STATIC_STRINGS);
 
   /**
-   * GcalEditDialog::writable:
+   * GcalEventEditorDialog::writable:
    *
    * Whether the current event can be edited or not.
    */
@@ -1314,48 +1314,48 @@ gcal_edit_dialog_class_init (GcalEditDialogClass *klass)
 
   g_object_class_install_properties (object_class, N_PROPS, properties);
 
-  gtk_widget_class_set_template_from_resource (widget_class, 
"/org/gnome/calendar/ui/event-editor/gcal-edit-dialog.ui");
+  gtk_widget_class_set_template_from_resource (widget_class, 
"/org/gnome/calendar/ui/event-editor/gcal-event-editor-dialog.ui");
 
   /* Alarms */
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, five_minutes_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, ten_minutes_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, thirty_minutes_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, one_hour_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, one_day_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, two_days_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, three_days_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, one_week_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, alarms_popover);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, new_alarm_row);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, five_minutes_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, ten_minutes_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, thirty_minutes_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, one_hour_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, one_day_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, two_days_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, three_days_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, one_week_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, alarms_popover);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, new_alarm_row);
   /* Buttons */
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, done_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, cancel_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, delete_button);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, sources_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, done_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, cancel_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, delete_button);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, sources_button);
   /* Entries */
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, summary_entry);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, start_time_selector);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, start_date_selector);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, end_time_selector);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, end_date_selector);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, location_entry);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, event_start_label);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, event_end_label);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, summary_entry);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, start_time_selector);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, start_date_selector);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, end_time_selector);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, end_date_selector);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, location_entry);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, event_start_label);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, event_end_label);
   /* Other */
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, alarms_listbox);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, notes_text);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, all_day_switch);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, titlebar);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, title_label);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, subtitle_label);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, lock);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, number_of_occurrences_spin);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, repeat_combo);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, repeat_duration_combo);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, scrolled_window);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, source_image);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, sources_popover);
-  gtk_widget_class_bind_template_child (widget_class, GcalEditDialog, until_date_selector);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, alarms_listbox);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, notes_text);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, all_day_switch);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, titlebar);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, title_label);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, subtitle_label);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, lock);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, number_of_occurrences_spin);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, repeat_combo);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, repeat_duration_combo);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, scrolled_window);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, source_image);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, sources_popover);
+  gtk_widget_class_bind_template_child (widget_class, GcalEventEditorDialog, until_date_selector);
 
 
   /* callbacks */
@@ -1372,7 +1372,7 @@ gcal_edit_dialog_class_init (GcalEditDialogClass *klass)
 }
 
 static void
-gcal_edit_dialog_init (GcalEditDialog *self)
+gcal_event_editor_dialog_init (GcalEventEditorDialog *self)
 {
   self->alarms = g_ptr_array_new_with_free_func (e_cal_component_alarm_free);
   self->writable = TRUE;
@@ -1386,20 +1386,20 @@ gcal_edit_dialog_init (GcalEditDialog *self)
 }
 
 /**
- * gcal_edit_dialog_new:
+ * gcal_event_editor_dialog_new:
  *
- * Creates a new #GcalEditDialog
+ * Creates a new #GcalEventEditorDialog
  *
- * Returns: (transfer full): a #GcalEditDialog
+ * Returns: (transfer full): a #GcalEventEditorDialog
  */
 GtkWidget*
-gcal_edit_dialog_new (void)
+gcal_event_editor_dialog_new (void)
 {
-  return g_object_new (GCAL_TYPE_EDIT_DIALOG, NULL);
+  return g_object_new (GCAL_TYPE_EVENT_EDITOR_DIALOG, NULL);
 }
 
 /**
- * gcal_edit_dialog_set_event_is_new:
+ * gcal_event_editor_dialog_set_event_is_new:
  * @dialog: a #GcalDialog
  * @event_is_new: %TRUE if the event is new, %FALSE otherwise
  *
@@ -1407,8 +1407,8 @@ gcal_edit_dialog_new (void)
  * The @dialog will adapt it's UI elements to reflect that.
  */
 void
-gcal_edit_dialog_set_event_is_new (GcalEditDialog *self,
-                                   gboolean        event_is_new)
+gcal_event_editor_dialog_set_event_is_new (GcalEventEditorDialog *self,
+                                           gboolean               event_is_new)
 {
   self->event_is_new = event_is_new;
 
@@ -1416,7 +1416,7 @@ gcal_edit_dialog_set_event_is_new (GcalEditDialog *self,
 }
 
 /**
- * gcal_edit_dialog_get_event:
+ * gcal_event_editor_dialog_get_event:
  * @dialog: a #GcalDialog
  *
  * Retrieves the current event being edited by the @dialog.
@@ -1424,15 +1424,15 @@ gcal_edit_dialog_set_event_is_new (GcalEditDialog *self,
  * Returns: (transfer none)(nullable): a #GcalEvent
  */
 GcalEvent*
-gcal_edit_dialog_get_event (GcalEditDialog *self)
+gcal_event_editor_dialog_get_event (GcalEventEditorDialog *self)
 {
-  g_return_val_if_fail (GCAL_IS_EDIT_DIALOG (self), NULL);
+  g_return_val_if_fail (GCAL_IS_EVENT_EDITOR_DIALOG (self), NULL);
 
   return self->event;
 }
 
 /**
- * gcal_edit_dialog_set_event:
+ * gcal_event_editor_dialog_set_event:
  * @dialog: a #GcalDialog
  * @event: (nullable): a #GcalEvent
  *
@@ -1440,8 +1440,8 @@ gcal_edit_dialog_get_event (GcalEditDialog *self)
  * %NULL, the current event information is unset.
  */
 void
-gcal_edit_dialog_set_event (GcalEditDialog *self,
-                            GcalEvent      *event)
+gcal_event_editor_dialog_set_event (GcalEventEditorDialog *self,
+                                    GcalEvent             *event)
 {
   g_autoptr (GcalEvent) cloned_event = NULL;
   GcalRecurrenceLimitType limit_type;
@@ -1457,7 +1457,7 @@ gcal_edit_dialog_set_event (GcalEditDialog *self,
 
   GCAL_ENTRY;
 
-  g_return_if_fail (GCAL_IS_EDIT_DIALOG (self));
+  g_return_if_fail (GCAL_IS_EVENT_EDITOR_DIALOG (self));
 
   g_clear_object (&self->event);
 
@@ -1513,7 +1513,7 @@ gcal_edit_dialog_set_event (GcalEditDialog *self,
   calendar = gcal_event_get_calendar (cloned_event);
 
   /* Clear event data */
-  gcal_edit_dialog_clear_data (self);
+  gcal_event_editor_dialog_clear_data (self);
 
   /* update sources list */
   if (self->sources_menu != NULL)
@@ -1602,9 +1602,9 @@ out:
 }
 
 gboolean
-gcal_edit_dialog_get_recurrence_changed (GcalEditDialog *self)
+gcal_event_editor_dialog_get_recurrence_changed (GcalEventEditorDialog *self)
 {
-  g_return_val_if_fail (GCAL_IS_EDIT_DIALOG (self), FALSE);
+  g_return_val_if_fail (GCAL_IS_EVENT_EDITOR_DIALOG (self), FALSE);
 
   return self->recurrence_changed;
 }
diff --git a/src/gui/event-editor/gcal-event-editor-dialog.h b/src/gui/event-editor/gcal-event-editor-dialog.h
new file mode 100644
index 00000000..0de82d58
--- /dev/null
+++ b/src/gui/event-editor/gcal-event-editor-dialog.h
@@ -0,0 +1,49 @@
+/* gcal-event-editor-dialog.h
+ *
+ * Copyright (C) 2015 Erick PĂ©rez Castellanos <erickpc gnome org>
+ *               2020 Georges Basile Stavracas Neto <gbsneto gnome org>
+ *
+ * gnome-calendar is free software: you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation, either version 3 of the License, or
+ * (at your option) any later version.
+ *
+ * gnome-calendar is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
+ * See the GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program.  If not, see <http://www.gnu.org/licenses/>.
+ */
+
+#pragma once
+
+#include "gcal-event.h"
+#include "gcal-manager.h"
+
+
+G_BEGIN_DECLS
+
+#define GCAL_RESPONSE_DELETE_EVENT 2
+#define GCAL_RESPONSE_SAVE_EVENT   4
+#define GCAL_RESPONSE_CREATE_EVENT 6
+
+#define GCAL_TYPE_EVENT_EDITOR_DIALOG (gcal_event_editor_dialog_get_type ())
+G_DECLARE_FINAL_TYPE (GcalEventEditorDialog, gcal_event_editor_dialog, GCAL, EVENT_EDITOR_DIALOG, GtkDialog);
+
+GtkWidget*           gcal_event_editor_dialog_new                (void);
+
+void                 gcal_event_editor_dialog_set_event_is_new   (GcalEventEditorDialog *dialog,
+                                                                  gboolean               event_is_new);
+
+GcalEvent*           gcal_event_editor_dialog_get_event          (GcalEventEditorDialog *self);
+
+void                 gcal_event_editor_dialog_set_event          (GcalEventEditorDialog *self,
+                                                                  GcalEvent             *event);
+
+gboolean             gcal_event_editor_dialog_get_recurrence_changed   (GcalEventEditorDialog *self);
+
+GcalRecurrenceModType gcal_event_editor_dialog_get_recurrence_mod_type (GcalEventEditorDialog *self);
+
+G_END_DECLS
diff --git a/src/gui/event-editor/gcal-edit-dialog.ui b/src/gui/event-editor/gcal-event-editor-dialog.ui
similarity index 92%
rename from src/gui/event-editor/gcal-edit-dialog.ui
rename to src/gui/event-editor/gcal-event-editor-dialog.ui
index c28c22bb..f0680985 100644
--- a/src/gui/event-editor/gcal-edit-dialog.ui
+++ b/src/gui/event-editor/gcal-event-editor-dialog.ui
@@ -1,6 +1,6 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <interface>
-  <template class="GcalEditDialog" parent="GtkDialog">
+  <template class="GcalEventEditorDialog" parent="GtkDialog">
     <property name="can_focus">False</property>
     <property name="resizable">False</property>
     <property name="modal">True</property>
@@ -17,12 +17,12 @@
             <property name="label" translatable="yes">Cancel</property>
             <property name="visible">True</property>
             <property name="can_focus">True</property>
-            <signal name="clicked" handler="on_action_button_clicked_cb" object="GcalEditDialog" 
swapped="no"/>
+            <signal name="clicked" handler="on_action_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no"/>
           </object>
         </child>
         <child>
           <object class="GtkImage" id="lock">
-            <property name="visible" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default|invert-boolean" />
+            <property name="visible" bind-source="GcalEventEditorDialog" bind-property="writable" 
bind-flags="default|invert-boolean" />
             <property name="icon_name">changes-prevent-symbolic</property>
             <property name="icon_size">1</property>
           </object>
@@ -33,7 +33,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="popover">sources_popover</property>
-            <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+            <property name="sensitive" bind-source="GcalEventEditorDialog" bind-property="writable" 
bind-flags="default" />
             <property name="tooltip-text" translatable="yes">Click to select the calendar</property>
             <style>
               <class name="flat"/>
@@ -110,7 +110,7 @@
             <property name="visible">True</property>
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
-            <signal name="clicked" handler="on_action_button_clicked_cb" object="GcalEditDialog" 
swapped="no"/>
+            <signal name="clicked" handler="on_action_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no"/>
             <style>
               <class name="suggested-action"/>
             </style>
@@ -143,7 +143,7 @@
                   <object class="GtkListBox">
                     <property name="visible">True</property>
                     <property name="selection-mode">none</property>
-                    <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+                    <property name="sensitive" bind-source="GcalEventEditorDialog" bind-property="writable" 
bind-flags="default" />
 
                     <style>
                       <class name="frame" />
@@ -161,9 +161,9 @@
                             <property name="visible">True</property>
                             <property name="valign">center</property>
                             <property name="can_focus">True</property>
-                            <property name="editable" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
-                            <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
-                            <signal name="notify::text" handler="on_summary_entry_changed_cb" 
object="GcalEditDialog" swapped="no"/>
+                            <property name="editable" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
+                            <property name="sensitive" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
+                            <signal name="notify::text" handler="on_summary_entry_changed_cb" 
object="GcalEventEditorDialog" swapped="no"/>
                           </object>
                         </child>
 
@@ -183,9 +183,9 @@
                             <property name="valign">center</property>
                             <property name="can_focus">True</property>
                             <property name="secondary_icon_name">find-location-symbolic</property>
-                            <property name="editable" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
-                            <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
-                            <signal name="notify::text" handler="on_location_entry_changed_cb" 
object="GcalEditDialog" swapped="no"/>
+                            <property name="editable" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
+                            <property name="sensitive" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
+                            <signal name="notify::text" handler="on_location_entry_changed_cb" 
object="GcalEventEditorDialog" swapped="no"/>
                           </object>
                         </child>
 
@@ -213,7 +213,7 @@
                   <object class="GtkListBox">
                     <property name="visible">True</property>
                     <property name="selection-mode">none</property>
-                    <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+                    <property name="sensitive" bind-source="GcalEventEditorDialog" bind-property="writable" 
bind-flags="default" />
 
                     <style>
                       <class name="frame" />
@@ -232,8 +232,8 @@
                             <property name="can_focus">True</property>
                             <property name="valign">center</property>
                             <property name="halign">end</property>
-                            <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
-                            <signal name="notify::active" handler="on_all_day_switch_active_changed_cb" 
object="GcalEditDialog" swapped="no"/>
+                            <property name="sensitive" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
+                            <signal name="notify::active" handler="on_all_day_switch_active_changed_cb" 
object="GcalEventEditorDialog" swapped="no"/>
                           </object>
                         </child>
 
@@ -270,7 +270,7 @@
                                 <property name="can_focus">True</property>
                                 <property name="valign">center</property>
                                 <property name="input-hints">no-emoji</property>
-                                <signal name="notify::date" handler="sync_datetimes" object="GcalEditDialog" 
swapped="yes" />
+                                <signal name="notify::date" handler="sync_datetimes" 
object="GcalEventEditorDialog" swapped="yes" />
                               </object>
                             </child>
 
@@ -278,7 +278,7 @@
                               <object class="GcalTimeSelector" id="start_time_selector">
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
-                                <signal name="notify::time" handler="sync_datetimes" object="GcalEditDialog" 
swapped="yes" />
+                                <signal name="notify::time" handler="sync_datetimes" 
object="GcalEventEditorDialog" swapped="yes" />
                               </object>
                             </child>
 
@@ -318,7 +318,7 @@
                                 <property name="can_focus">True</property>
                                 <property name="valign">center</property>
                                 <property name="input-hints">no-emoji</property>
-                                <signal name="notify::date" handler="sync_datetimes" object="GcalEditDialog" 
swapped="yes" />
+                                <signal name="notify::date" handler="sync_datetimes" 
object="GcalEventEditorDialog" swapped="yes" />
                               </object>
                             </child>
 
@@ -326,7 +326,7 @@
                               <object class="GcalTimeSelector" id="end_time_selector">
                                 <property name="visible">True</property>
                                 <property name="can_focus">True</property>
-                                <signal name="notify::time" handler="sync_datetimes" object="GcalEditDialog" 
swapped="yes" />
+                                <signal name="notify::time" handler="sync_datetimes" 
object="GcalEventEditorDialog" swapped="yes" />
                               </object>
                             </child>
 
@@ -348,8 +348,8 @@
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
                             <property name="valign">center</property>
-                            <signal name="changed" handler="on_repeat_type_changed_cb" 
object="GcalEditDialog" swapped="no"/>
-                            <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+                            <signal name="changed" handler="on_repeat_type_changed_cb" 
object="GcalEventEditorDialog" swapped="no"/>
+                            <property name="sensitive" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
                             <items>
                               <item translatable="yes" id="no_repeat">No Repeat</item>
                               <item translatable="yes" id="daily">Daily</item>
@@ -377,7 +377,7 @@
                             <property name="visible">True</property>
                             <property name="can_focus">False</property>
                             <property name="valign">center</property>
-                            <signal name="changed" handler="on_repeat_duration_changed_cb" 
object="GcalEditDialog" swapped="no"/>
+                            <signal name="changed" handler="on_repeat_duration_changed_cb" 
object="GcalEventEditorDialog" swapped="no"/>
                             <items>
                               <item translatable="yes" id="forever">Forever</item>
                               <item translatable="yes" id="number_of_occurrences_spin">No. of 
occurrences</item>
@@ -457,13 +457,13 @@
                         <property name="visible">True</property>
                         <property name="can_focus">False</property>
                         <property name="selection_mode">none</property>
-                        <signal name="row-activated" handler="on_alarms_listbox_row_activated_cb" 
object="GcalEditDialog" swapped="no" />
-                        <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+                        <signal name="row-activated" handler="on_alarms_listbox_row_activated_cb" 
object="GcalEventEditorDialog" swapped="no" />
+                        <property name="sensitive" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
 
                         <child>
                           <object class="GtkListBoxRow" id="new_alarm_row">
                             <property name="visible">True</property>
-                            <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+                            <property name="sensitive" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
 
                             <child>
                               <object class="GtkLabel">
@@ -516,8 +516,8 @@
                         <property name="left_margin">6</property>
                         <property name="right_margin">6</property>
                         <property name="sensitive">True</property>
-                        <property name="editable" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
-                        <property name="cursor_visible" bind-source="GcalEditDialog" 
bind-property="writable" bind-flags="default" />
+                        <property name="editable" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
+                        <property name="cursor_visible" bind-source="GcalEventEditorDialog" 
bind-property="writable" bind-flags="default" />
                         <property name="wrap_mode">GTK_WRAP_WORD_CHAR</property>
                       </object>
                     </child>
@@ -531,8 +531,8 @@
                     <property name="visible">True</property>
                     <property name="halign">end</property>
                     <property name="can_focus">True</property>
-                    <signal name="clicked" handler="on_action_button_clicked_cb" object="GcalEditDialog" 
swapped="no"/>
-                    <property name="sensitive" bind-source="GcalEditDialog" bind-property="writable" 
bind-flags="default" />
+                    <signal name="clicked" handler="on_action_button_clicked_cb" 
object="GcalEventEditorDialog" swapped="no"/>
+                    <property name="sensitive" bind-source="GcalEventEditorDialog" bind-property="writable" 
bind-flags="default" />
                     <child>
                       <object class="GtkLabel" id="delete_label">
                         <property name="visible">True</property>
@@ -571,7 +571,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">5 minutes</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -580,7 +580,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">10 minutes</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -589,7 +589,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">30 minutes</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -598,7 +598,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">1 hour</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -606,7 +606,7 @@
             <property name="visible">True</property>
             <property name="can_focus">True</property>
             <property name="text" translatable="yes">1 day</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -615,7 +615,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">2 days</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -624,7 +624,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">3 days</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
         <child>
@@ -633,7 +633,7 @@
             <property name="can_focus">True</property>
             <property name="receives_default">True</property>
             <property name="text" translatable="yes">1 week</property>
-            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEditDialog" 
swapped="no" />
+            <signal name="clicked" handler="on_add_alarm_button_clicked_cb" object="GcalEventEditorDialog" 
swapped="no" />
           </object>
         </child>
       </object>
diff --git a/src/gui/event-editor/meson.build b/src/gui/event-editor/meson.build
index fd969335..8667b2e9 100644
--- a/src/gui/event-editor/meson.build
+++ b/src/gui/event-editor/meson.build
@@ -11,7 +11,7 @@ sources += files(
   'gcal-date-chooser.c',
   'gcal-date-chooser-day.c',
   'gcal-date-selector.c',
-  'gcal-edit-dialog.c',
+  'gcal-event-editor-dialog.c',
   'gcal-multi-choice.c',
   'gcal-time-selector.c',
 )
diff --git a/src/gui/gcal-window.c b/src/gui/gcal-window.c
index 7f238810..24338cc2 100644
--- a/src/gui/gcal-window.c
+++ b/src/gui/gcal-window.c
@@ -23,7 +23,7 @@
 #include "gcal-calendar-popover.h"
 #include "config.h"
 #include "gcal-debug.h"
-#include "gcal-edit-dialog.h"
+#include "gcal-event-editor-dialog.h"
 #include "gcal-event-widget.h"
 #include "gcal-context.h"
 #include "gcal-manager.h"
@@ -59,10 +59,10 @@
  * ## Edit dialog
  *
  * When an event is clicked, the views send the `event-activated`
- * signal. #GcalWindow responds to this signal opening #GcalEditDialog
+ * signal. #GcalWindow responds to this signal opening #GcalEventEditorDialog
  * with the clicked event.
  *
- * When #GcalEditDialog sends a response, #GcalWindow reacts by
+ * When #GcalEventEditorDialog sends a response, #GcalWindow reacts by
  * either propagating to gcal_manager_update_event(), or hiding
  * the delete event widgets from the views.
  *
@@ -122,7 +122,7 @@ struct _GcalWindow
 
   /* day, week, month, year, list */
   GtkWidget          *views [6];
-  GtkWidget          *edit_dialog;
+  GtkWidget          *event_editor;
   gboolean            subscribed;
 
   GcalContext        *context;
@@ -392,10 +392,10 @@ on_window_new_event_cb (GSimpleAction *action,
   default_calendar = gcal_manager_get_default_calendar (manager);
   event = gcal_event_new (default_calendar, comp, NULL);
 
-  gcal_edit_dialog_set_event_is_new (GCAL_EDIT_DIALOG (self->edit_dialog), TRUE);
-  gcal_edit_dialog_set_event (GCAL_EDIT_DIALOG (self->edit_dialog), event);
+  gcal_event_editor_dialog_set_event_is_new (GCAL_EVENT_EDITOR_DIALOG (self->event_editor), TRUE);
+  gcal_event_editor_dialog_set_event (GCAL_EVENT_EDITOR_DIALOG (self->event_editor), event);
 
-  gtk_widget_show (self->edit_dialog);
+  gtk_widget_show (self->event_editor);
 }
 
 static void
@@ -610,10 +610,10 @@ edit_event (GcalQuickAddPopover *popover,
             GcalEvent           *event,
             GcalWindow          *window)
 {
-  gcal_edit_dialog_set_event_is_new (GCAL_EDIT_DIALOG (window->edit_dialog), TRUE);
-  gcal_edit_dialog_set_event (GCAL_EDIT_DIALOG (window->edit_dialog), event);
+  gcal_event_editor_dialog_set_event_is_new (GCAL_EVENT_EDITOR_DIALOG (window->event_editor), TRUE);
+  gcal_event_editor_dialog_set_event (GCAL_EVENT_EDITOR_DIALOG (window->event_editor), event);
 
-  gtk_widget_show (window->edit_dialog);
+  gtk_widget_show (window->event_editor);
 }
 
 static void
@@ -633,10 +633,10 @@ create_event_detailed_cb (GcalView *view,
   default_calendar = gcal_manager_get_default_calendar (manager);
   event = gcal_event_new (default_calendar, comp, NULL);
 
-  gcal_edit_dialog_set_event_is_new (GCAL_EDIT_DIALOG (window->edit_dialog), TRUE);
-  gcal_edit_dialog_set_event (GCAL_EDIT_DIALOG (window->edit_dialog), event);
+  gcal_event_editor_dialog_set_event_is_new (GCAL_EVENT_EDITOR_DIALOG (window->event_editor), TRUE);
+  gcal_event_editor_dialog_set_event (GCAL_EVENT_EDITOR_DIALOG (window->event_editor), event);
 
-  gtk_widget_show (window->edit_dialog);
+  gtk_widget_show (window->event_editor);
 
   g_clear_object (&comp);
 }
@@ -650,10 +650,10 @@ event_activated (GcalView        *view,
   GcalEvent *event;
 
   event = gcal_event_widget_get_event (event_widget);
-  gcal_edit_dialog_set_event_is_new (GCAL_EDIT_DIALOG (window->edit_dialog), FALSE);
-  gcal_edit_dialog_set_event (GCAL_EDIT_DIALOG (window->edit_dialog), event);
+  gcal_event_editor_dialog_set_event_is_new (GCAL_EVENT_EDITOR_DIALOG (window->event_editor), FALSE);
+  gcal_event_editor_dialog_set_event (GCAL_EVENT_EDITOR_DIALOG (window->event_editor), event);
 
-  gtk_widget_show (window->edit_dialog);
+  gtk_widget_show (window->event_editor);
 }
 
 static void
@@ -661,11 +661,11 @@ edit_dialog_closed (GtkDialog *dialog,
                     gint       response,
                     gpointer   user_data)
 {
+  GcalEventEditorDialog *edit_dialog;
   GcalRecurrenceModType mod;
   GcalCalendar *calendar;
   GcalManager *manager;
   GcalWindow *window;
-  GcalEditDialog *edit_dialog;
   GcalEvent *event;
   GcalView *view;
   GList *widgets;
@@ -674,13 +674,13 @@ edit_dialog_closed (GtkDialog *dialog,
 
   window = GCAL_WINDOW (user_data);
   manager = gcal_context_get_manager (window->context);
-  edit_dialog = GCAL_EDIT_DIALOG (dialog);
-  event = gcal_edit_dialog_get_event (edit_dialog);
+  edit_dialog = GCAL_EVENT_EDITOR_DIALOG (dialog);
+  event = gcal_event_editor_dialog_get_event (edit_dialog);
   view = GCAL_VIEW (window->views[window->active_view]);
   mod = GCAL_RECURRENCE_MOD_THIS_ONLY;
   calendar = gcal_event_get_calendar (event);
 
-  if (!gcal_edit_dialog_get_recurrence_changed (edit_dialog) &&
+  if (!gcal_event_editor_dialog_get_recurrence_changed (edit_dialog) &&
       gcal_event_has_recurrence (event) &&
       (response != GCAL_RESPONSE_CREATE_EVENT &&
        response != GTK_RESPONSE_CANCEL &&
@@ -741,7 +741,7 @@ edit_dialog_closed (GtkDialog *dialog,
 
   gtk_widget_hide (GTK_WIDGET (dialog));
 
-  gcal_edit_dialog_set_event (edit_dialog, NULL);
+  gcal_event_editor_dialog_set_event (edit_dialog, NULL);
 
   GCAL_EXIT;
 }
@@ -880,7 +880,7 @@ gcal_window_constructed (GObject *object)
   g_object_bind_property (self, "context", self->week_view, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
   g_object_bind_property (self, "context", self->month_view, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
   g_object_bind_property (self, "context", self->year_view, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
-  g_object_bind_property (self, "context", self->edit_dialog, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
+  g_object_bind_property (self, "context", self->event_editor, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
   g_object_bind_property (self, "context", self->quick_add_popover, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
   g_object_bind_property (self, "context", self->search_button, "context", G_BINDING_DEFAULT | 
G_BINDING_SYNC_CREATE);
 
@@ -1009,7 +1009,7 @@ gcal_window_class_init (GcalWindowClass *klass)
 
   g_type_ensure (GCAL_TYPE_CALENDAR_MANAGEMENT_DIALOG);
   g_type_ensure (GCAL_TYPE_CALENDAR_POPOVER);
-  g_type_ensure (GCAL_TYPE_EDIT_DIALOG);
+  g_type_ensure (GCAL_TYPE_EVENT_EDITOR_DIALOG);
   g_type_ensure (GCAL_TYPE_MANAGER);
   g_type_ensure (GCAL_TYPE_MONTH_VIEW);
   g_type_ensure (GCAL_TYPE_QUICK_ADD_POPOVER);
@@ -1062,7 +1062,7 @@ gcal_window_class_init (GcalWindowClass *klass)
   gtk_widget_class_bind_template_child (widget_class, GcalWindow, back_button);
   gtk_widget_class_bind_template_child (widget_class, GcalWindow, calendars_button);
   gtk_widget_class_bind_template_child (widget_class, GcalWindow, calendar_popover);
-  gtk_widget_class_bind_template_child (widget_class, GcalWindow, edit_dialog);
+  gtk_widget_class_bind_template_child (widget_class, GcalWindow, event_editor);
   gtk_widget_class_bind_template_child (widget_class, GcalWindow, forward_button);
   gtk_widget_class_bind_template_child (widget_class, GcalWindow, header_bar);
   gtk_widget_class_bind_template_child (widget_class, GcalWindow, main_box);
diff --git a/src/gui/gcal-window.ui b/src/gui/gcal-window.ui
index 9f4483b7..99aa25cc 100644
--- a/src/gui/gcal-window.ui
+++ b/src/gui/gcal-window.ui
@@ -296,7 +296,7 @@
     <property name="transient_for">GcalWindow</property>
     <signal name="delete-event" handler="gtk_widget_hide_on_delete" object="GcalWindow" swapped="no" />
   </object>
-  <object class="GcalEditDialog" id="edit_dialog">
+  <object class="GcalEventEditorDialog" id="event_editor">
     <property name="visible">False</property>
     <property name="transient_for">GcalWindow</property>
     <signal name="response" handler="edit_dialog_closed" object="GcalWindow" swapped="no"/>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]