diff options
author | Rodrigo Moya <rodrigo@novell.com> | 2005-01-19 00:18:05 +0800 |
---|---|---|
committer | Rodrigo Moya <rodrigo@src.gnome.org> | 2005-01-19 00:18:05 +0800 |
commit | dd64b26d1b1a04b26414449a29ed73eebd9cb958 (patch) | |
tree | 13ec56d4ee4e3b30a766b752c4405fcf52f6cfc3 /calendar | |
parent | 01ca679d17f577ce7d2e7c74a634c609e253de3a (diff) | |
download | gsoc2013-evolution-dd64b26d1b1a04b26414449a29ed73eebd9cb958.tar.gz gsoc2013-evolution-dd64b26d1b1a04b26414449a29ed73eebd9cb958.tar.zst gsoc2013-evolution-dd64b26d1b1a04b26414449a29ed73eebd9cb958.zip |
killed warnings. (e_week_view_start_editing_event): do nothing if the
2005-01-18 Rodrigo Moya <rodrigo@novell.com>
* gui/e-week-view.c (process_component): killed warnings.
(e_week_view_start_editing_event): do nothing if the calendar is
read only.
* gui/e-day-view.c (e_day_view_start_editing_event): ditto.
svn path=/trunk/; revision=28440
Diffstat (limited to 'calendar')
-rw-r--r-- | calendar/ChangeLog | 8 | ||||
-rw-r--r-- | calendar/gui/e-day-view.c | 4 | ||||
-rw-r--r-- | calendar/gui/e-week-view.c | 7 |
3 files changed, 17 insertions, 2 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog index 1d63733b7c..bce454a3a9 100644 --- a/calendar/ChangeLog +++ b/calendar/ChangeLog @@ -1,3 +1,11 @@ +2005-01-18 Rodrigo Moya <rodrigo@novell.com> + + * gui/e-week-view.c (process_component): killed warnings. + (e_week_view_start_editing_event): do nothing if the calendar is + read only. + + * gui/e-day-view.c (e_day_view_start_editing_event): ditto. + 2005-01-18 Harish Krishnaswamy <kharish@novell.com> * gui/dialogs/cal-attachment-bar.c diff --git a/calendar/gui/e-day-view.c b/calendar/gui/e-day-view.c index 8b9e39149e..485a930f89 100644 --- a/calendar/gui/e-day-view.c +++ b/calendar/gui/e-day-view.c @@ -5519,6 +5519,7 @@ e_day_view_start_editing_event (EDayView *day_view, EDayViewEvent *event; ETextEventProcessor *event_processor = NULL; ETextEventProcessorCommand command; + gboolean read_only; #if 0 g_print ("In e_day_view_start_editing_event\n"); @@ -5537,6 +5538,9 @@ e_day_view_start_editing_event (EDayView *day_view, event_num); } + if (!e_cal_is_read_only (event->comp_data->client, &read_only, NULL) || read_only) + return; + /* If the event is not shown, don't try to edit it. */ if (!event->canvas_item) return; diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c index 893254252a..d829675624 100644 --- a/calendar/gui/e-week-view.c +++ b/calendar/gui/e-week-view.c @@ -306,8 +306,7 @@ time_range_changed_cb (ECalModel *model, time_t start_time, time_t end_time, gpo static void process_component (EWeekView *week_view, ECalModelComponent *comp_data) { - EWeekViewEvent *event; - gint event_num, num_days; + gint num_days; ECalComponent *comp = NULL; AddEventData add_event_data; const char *uid, *rid; @@ -2792,6 +2791,7 @@ e_week_view_start_editing_event (EWeekView *week_view, ETextEventProcessor *event_processor = NULL; ETextEventProcessorCommand command; ECalModelComponent *comp_data; + gboolean read_only; /* If we are already editing the event, just return. */ if (event_num == week_view->editing_event_num @@ -2802,6 +2802,9 @@ e_week_view_start_editing_event (EWeekView *week_view, span = &g_array_index (week_view->spans, EWeekViewEventSpan, event->spans_index + span_num); + if (!e_cal_is_read_only (event->comp_data->client, &read_only, NULL) || read_only) + return FALSE; + /* If the event is not shown, don't try to edit it. */ if (!span->text_item) return FALSE; |