aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2012-09-11 21:42:46 +0800
committerMilan Crha <mcrha@redhat.com>2012-09-11 21:42:46 +0800
commit24bc436a653ab766c2c9cf91fa21b58c52aafecf (patch)
treed6cc47ab0befeea60b3940190f0914580dd024f0 /modules
parent14e9bf1673c0ce53fc4e97a963b369d344c038cd (diff)
downloadgsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.tar
gsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.tar.gz
gsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.tar.bz2
gsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.tar.lz
gsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.tar.xz
gsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.tar.zst
gsoc2013-evolution-24bc436a653ab766c2c9cf91fa21b58c52aafecf.zip
Make sure the selected days in the calendar matches shown days
Diffstat (limited to 'modules')
-rw-r--r--modules/calendar/e-cal-shell-view-private.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/modules/calendar/e-cal-shell-view-private.c b/modules/calendar/e-cal-shell-view-private.c
index 012b9cf03e..9eb8d66dcc 100644
--- a/modules/calendar/e-cal-shell-view-private.c
+++ b/modules/calendar/e-cal-shell-view-private.c
@@ -203,6 +203,22 @@ cal_shell_view_date_navigator_selection_changed_cb (ECalShellView *cal_shell_vie
gnome_calendar_set_range_selected (calendar, TRUE);
gnome_calendar_notify_dates_shown_changed (calendar);
+
+ g_signal_handlers_block_by_func (calitem,
+ cal_shell_view_date_navigator_selection_changed_cb, cal_shell_view);
+
+ /* make sure the selected days in the calendar matches shown days */
+ e_cal_model_get_time_range (model, &start, &end);
+
+ time_to_gdate_with_zone (&start_date, start, timezone);
+ time_to_gdate_with_zone (&end_date, end, timezone);
+
+ g_date_subtract_days (&end_date, 1);
+
+ e_calendar_item_set_selection (calitem, &start_date, &end_date);
+
+ g_signal_handlers_unblock_by_func (calitem,
+ cal_shell_view_date_navigator_selection_changed_cb, cal_shell_view);
}
static gboolean