diff options
Diffstat (limited to 'calendar/gui')
-rw-r--r-- | calendar/gui/e-week-view-main-item.c | 9 | ||||
-rw-r--r-- | calendar/gui/e-week-view.c | 4 | ||||
-rw-r--r-- | calendar/gui/e-week-view.h | 1 |
3 files changed, 11 insertions, 3 deletions
diff --git a/calendar/gui/e-week-view-main-item.c b/calendar/gui/e-week-view-main-item.c index 87682a354a..de0a4198fe 100644 --- a/calendar/gui/e-week-view-main-item.c +++ b/calendar/gui/e-week-view-main-item.c @@ -264,13 +264,16 @@ e_week_view_main_item_draw_day (EWeekViewMainItem *wvmitem, /* If the day is selected, draw the blue background. */ selected = TRUE; - if (!GTK_WIDGET_HAS_FOCUS (week_view) - || week_view->selection_start_day == -1 + if (week_view->selection_start_day == -1 || week_view->selection_start_day > day || week_view->selection_end_day < day) selected = FALSE; if (selected) { - gdk_gc_set_foreground (gc, &week_view->colors[E_WEEK_VIEW_COLOR_SELECTED]); + if (GTK_WIDGET_HAS_FOCUS (week_view)) + gdk_gc_set_foreground (gc, &week_view->colors[E_WEEK_VIEW_COLOR_SELECTED]); + else + gdk_gc_set_foreground (gc, &week_view->colors[E_WEEK_VIEW_COLOR_SELECTED_UNFOCUSSED]); + if (week_view->multi_week_view) { gdk_draw_rectangle (drawable, gc, TRUE, x + 2, y + 1, diff --git a/calendar/gui/e-week-view.c b/calendar/gui/e-week-view.c index b1c3290798..f893eeadb1 100644 --- a/calendar/gui/e-week-view.c +++ b/calendar/gui/e-week-view.c @@ -565,6 +565,10 @@ e_week_view_realize (GtkWidget *widget) week_view->colors[E_WEEK_VIEW_COLOR_SELECTED].green = 0 * 257; week_view->colors[E_WEEK_VIEW_COLOR_SELECTED].blue = 156 * 257; + week_view->colors[E_WEEK_VIEW_COLOR_SELECTED_UNFOCUSSED].red = 16 * 257; + week_view->colors[E_WEEK_VIEW_COLOR_SELECTED_UNFOCUSSED].green = 78 * 257; + week_view->colors[E_WEEK_VIEW_COLOR_SELECTED_UNFOCUSSED].blue = 139 * 257; + week_view->colors[E_WEEK_VIEW_COLOR_DATES].red = 0 * 257; week_view->colors[E_WEEK_VIEW_COLOR_DATES].green = 0 * 257; week_view->colors[E_WEEK_VIEW_COLOR_DATES].blue = 0 * 257; diff --git a/calendar/gui/e-week-view.h b/calendar/gui/e-week-view.h index f45ca7eb1d..8723d14cf9 100644 --- a/calendar/gui/e-week-view.h +++ b/calendar/gui/e-week-view.h @@ -105,6 +105,7 @@ typedef enum E_WEEK_VIEW_COLOR_EVENT_TEXT, E_WEEK_VIEW_COLOR_GRID, E_WEEK_VIEW_COLOR_SELECTED, + E_WEEK_VIEW_COLOR_SELECTED_UNFOCUSSED, E_WEEK_VIEW_COLOR_DATES, E_WEEK_VIEW_COLOR_DATES_SELECTED, E_WEEK_VIEW_COLOR_TODAY, |