year-view: only apply widget dates to multiday events

Single day events won't ever show slanted edges.
This commit is contained in:
Georges Basile Stavracas Neto
2016-02-16 03:47:31 +01:00
parent 004af2893f
commit 5d96c11c55
+5 -2
View File
@@ -335,8 +335,11 @@ add_event_to_day_array (GcalYearView *year_view,
* Setup the event widget's custom dates, so the slanted edges are * Setup the event widget's custom dates, so the slanted edges are
* applied properly * applied properly
*/ */
gcal_event_widget_set_date_start (GCAL_EVENT_WIDGET (cloned_child), date); if (gcal_event_is_multiday (event))
gcal_event_widget_set_date_end (GCAL_EVENT_WIDGET (cloned_child), second_date); {
gcal_event_widget_set_date_start (GCAL_EVENT_WIDGET (cloned_child), date);
gcal_event_widget_set_date_end (GCAL_EVENT_WIDGET (cloned_child), second_date);
}
days_widgets_array[i] = g_list_insert_sorted (days_widgets_array[i], days_widgets_array[i] = g_list_insert_sorted (days_widgets_array[i],
cloned_child, cloned_child,