/// <summary>
        /// Apply a Style to a GlobalCalendarDayButton.
        /// </summary>
        /// <param name="button">The button.</param>
        internal void ApplyDayButtonStyle(GlobalCalendarDayButton button)
        {
            Debug.Assert(button != null, "button should not be null!");

            DateTime? date = button.GetDateNullable();
            CalendarDayButtonStyleSelector selector = CalendarDayButtonStyleSelector;
            Style style = CalendarDayButtonStyle;

            button.Style = (selector != null && date != null) ?
                selector.SelectStyle(date.Value, button) ?? style :
                style;
        }