aboutsummaryrefslogtreecommitdiffstats
path: root/modules
diff options
context:
space:
mode:
authorMilan Crha <mcrha@redhat.com>2012-09-11 20:53:31 +0800
committerMilan Crha <mcrha@redhat.com>2012-09-11 20:53:31 +0800
commit832de6f6d63b60f85e1144cd8afbe836dff4a565 (patch)
tree02c22fd4982ea2f783c78ddee2be281f21cdb129 /modules
parent218bd7d334aff1338d63eac7c5fd4c9d9f3d2f1c (diff)
downloadgsoc2013-evolution-832de6f6d63b60f85e1144cd8afbe836dff4a565.tar.gz
gsoc2013-evolution-832de6f6d63b60f85e1144cd8afbe836dff4a565.tar.zst
gsoc2013-evolution-832de6f6d63b60f85e1144cd8afbe836dff4a565.zip
Bug #683407 - Preserve week views in calendar when clicking one day
Diffstat (limited to 'modules')
-rw-r--r--modules/calendar/e-cal-shell-view-private.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/modules/calendar/e-cal-shell-view-private.c b/modules/calendar/e-cal-shell-view-private.c
index 2b5aa7e4f5..012b9cf03e 100644
--- a/modules/calendar/e-cal-shell-view-private.c
+++ b/modules/calendar/e-cal-shell-view-private.c
@@ -177,9 +177,12 @@ cal_shell_view_date_navigator_selection_changed_cb (ECalShellView *cal_shell_vie
(new_days_shown + 6) / 7);
switch_to = GNOME_CAL_MONTH_VIEW;
}
- } else if (new_days_shown == 7 && starts_on_week_start_day)
+ } else if (new_days_shown == 7 && starts_on_week_start_day) {
switch_to = GNOME_CAL_WEEK_VIEW;
- else {
+ } else if (new_days_shown == 1 && (view_type == GNOME_CAL_WORK_WEEK_VIEW || view_type == GNOME_CAL_WEEK_VIEW)) {
+ /* preserve week views when clicking on one day */
+ switch_to = view_type;
+ } else {
ECalendarView *calendar_view;
calendar_view = gnome_calendar_get_calendar_view (