private static void OnItemsSourceChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { DownListControl downListControl = d as DownListControl; if (downListControl == null) { return; } downListControl.ItemsSource = (IEnumerable <object>)e.NewValue; }
private static void OnCurrentTextChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { DownListControl downListControl = d as DownListControl; if (downListControl == null) { return; } downListControl.CurrentText = e.NewValue.ToString(); }