private static void MinimumPropertyChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { AudioFader control = d as AudioFader; if (control != null) { control.Update(); } }
private static object MinimumPropertyCoerce(DependencyObject d, object baseValue) { AudioFader control = d as AudioFader; if (control != null) { } return(baseValue); }
private static object ValuePropertyCoerce(DependencyObject d, object baseValue) { AudioFader control = d as AudioFader; if (control != null) { double NewValue = (double)baseValue; if (NewValue >= control.Maximum) { return(control.Maximum); } if (NewValue <= control.Minimum) { return(control.Minimum); } } return(baseValue); }