internal void Calendar_KeyDown(object sender, KeyRoutedEventArgs e) { Calendar c = sender as Calendar; Debug.Assert(c != null, "c should not be null!"); if (!e.Handled && c.IsEnabled) { e.Handled = ProcessCalendarKey(e); } }