From 5dd3854a03947190c6da46c9e30200f1aea7efb9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Danielle=20For=C3=A9?= Date: Tue, 17 Feb 2026 09:39:20 -0800 Subject: [PATCH] EventDialog: remove unused can_edit --- src/EventEdition/EventDialog.vala | 5 ----- src/EventEdition/GuestsPanel.vala | 1 - src/EventEdition/InfoPanel.vala | 3 +-- src/EventEdition/LocationPanel.vala | 2 -- src/EventEdition/ReminderPanel.vala | 1 - src/EventEdition/RepeatPanel.vala | 1 - 6 files changed, 1 insertion(+), 12 deletions(-) diff --git a/src/EventEdition/EventDialog.vala b/src/EventEdition/EventDialog.vala index cdc4946ff..49b27a387 100644 --- a/src/EventEdition/EventDialog.vala +++ b/src/EventEdition/EventDialog.vala @@ -32,11 +32,6 @@ public class EventDialog : Granite.Dialog { public ECal.Component original_ecal { get; private set; } public DateTime date_time { get; set; } - /** - * A boolean indicating whether we can edit the current event. - */ - public bool can_edit = true; - private ECal.ObjModType mod_type { get; private set; default = ECal.ObjModType.ALL; } private EventType event_type { get; private set; } diff --git a/src/EventEdition/GuestsPanel.vala b/src/EventEdition/GuestsPanel.vala index 926a0a5d7..24d167106 100644 --- a/src/EventEdition/GuestsPanel.vala +++ b/src/EventEdition/GuestsPanel.vala @@ -45,7 +45,6 @@ public class Maya.View.EventEdition.GuestsPanel : Gtk.Grid { margin_start = 12; margin_end = 12; row_spacing = 6; - set_sensitive (parent_dialog.can_edit); orientation = Gtk.Orientation.VERTICAL; guest_store = new Gtk.ListStore (2, typeof (string), typeof (string)); diff --git a/src/EventEdition/InfoPanel.vala b/src/EventEdition/InfoPanel.vala index c40df4931..2c26ad05f 100644 --- a/src/EventEdition/InfoPanel.vala +++ b/src/EventEdition/InfoPanel.vala @@ -75,7 +75,6 @@ public class Maya.View.EventEdition.InfoPanel : Gtk.Grid { margin_start = 12; margin_end = 12; column_spacing = 12; - sensitive = parent_dialog.can_edit; var from_label = new Granite.HeaderLabel (_("From:")); @@ -205,7 +204,7 @@ public class Maya.View.EventEdition.InfoPanel : Gtk.Grid { // Row: title & calendar attach (title_label, 0, 0, 1, 1); attach (title_entry, 0, 1, 1, 1); - if (calchooser.sources.length () > 1 && parent_dialog.can_edit) { + if (calchooser.sources.length () > 1) { attach (calendar_label, 1, 0, 4, 1); attach (calendar_button, 1, 1, 4, 1); } diff --git a/src/EventEdition/LocationPanel.vala b/src/EventEdition/LocationPanel.vala index a426a63cd..00187d535 100644 --- a/src/EventEdition/LocationPanel.vala +++ b/src/EventEdition/LocationPanel.vala @@ -63,7 +63,6 @@ public class Maya.View.EventEdition.LocationPanel : Gtk.Box { champlain_embed = new GtkChamplain.Embed (); point = new Maya.Marker (); - point.draggable = parent_dialog.can_edit; point.drag_finish.connect (() => { map_selected = true; find_location.begin (point.latitude, point.longitude); @@ -89,7 +88,6 @@ public class Maya.View.EventEdition.LocationPanel : Gtk.Box { margin_end = 12; orientation = VERTICAL; spacing = 6; - sensitive = parent_dialog.can_edit; add (location_label); add (location_entry); add (frame); diff --git a/src/EventEdition/ReminderPanel.vala b/src/EventEdition/ReminderPanel.vala index 0f72164b5..0b831fa04 100644 --- a/src/EventEdition/ReminderPanel.vala +++ b/src/EventEdition/ReminderPanel.vala @@ -64,7 +64,6 @@ public class Maya.View.EventEdition.ReminderPanel : Gtk.Box { margin_start = margin_end = 12; orientation = VERTICAL; - sensitive = parent_dialog.can_edit; add (reminder_label); add (frame); diff --git a/src/EventEdition/RepeatPanel.vala b/src/EventEdition/RepeatPanel.vala index 6b4a419c0..be88fb06a 100644 --- a/src/EventEdition/RepeatPanel.vala +++ b/src/EventEdition/RepeatPanel.vala @@ -29,7 +29,6 @@ public class Maya.View.EventEdition.RepeatPanel : Gtk.Bin { public RepeatPanel (EventDialog parent_dialog) { this.parent_dialog = parent_dialog; - sensitive = parent_dialog.can_edit; var reminder_label = new Granite.HeaderLabel (_("Repeat:"));