/// <summary> /// Handles changes to the TickStyle property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnTickStyleChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; PenLineCap oldTickStyle = (PenLineCap)e.OldValue; PenLineCap newTickStyle = SprocketControl.TickStyle; SprocketControl.OnTickStyleChanged(oldTickStyle, newTickStyle); }
/// <summary> /// Handles changes to the TickWidth property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnTickWidthChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl target = (SprocketControl)d; double oldTickWidth = (double)e.OldValue; double newTickWidth = target.TickWidth; target.OnTickWidthChanged(oldTickWidth, newTickWidth); }
/// <summary> /// Handles changes to the TickColor property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnTickColorChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; Color oldTickColor = (Color)e.OldValue; Color newTickColor = SprocketControl.TickColor; SprocketControl.OnTickColorChanged(oldTickColor, newTickColor); }
/// <summary> /// Handles changes to the TickCount property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnTickCountChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; int oldTickCount = (int)e.OldValue; int newTickCount = SprocketControl.TickCount; SprocketControl.OnTickCountChanged(oldTickCount, newTickCount); }
/// <summary> /// Handles changes to the StartAngle property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnStartAngleChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; double oldStartAngle = (double)e.OldValue; double newStartAngle = SprocketControl.StartAngle; SprocketControl.OnStartAngleChanged(oldStartAngle, newStartAngle); }
/// <summary> /// Handles changes to the Rotation property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnRotationChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; Direction oldRotation = (Direction)e.OldValue; Direction newRotation = SprocketControl.Rotation; SprocketControl.OnRotationChanged(oldRotation, newRotation); }
/// <summary> /// Handles changes to the Progress property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnProgressChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; double oldProgress = (double)e.OldValue; double newProgress = SprocketControl.Progress; SprocketControl.OnProgressChanged(oldProgress, newProgress); }
/// <summary> /// Handles changes to the IsIndeterminate property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnIsIndeterminateChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl target = (SprocketControl)d; bool oldIsIndeterminate = (bool)e.OldValue; bool newIsIndeterminate = target.IsIndeterminate; target.OnIsIndeterminateChanged(oldIsIndeterminate, newIsIndeterminate); }
/// <summary> /// Handles changes to the Interval property. /// </summary> /// <param name="d">SprocketControlControl</param> /// <param name="e">DependencyProperty changed event arguments</param> private static void OnIntervalChanged(DependencyObject d, DependencyPropertyChangedEventArgs e) { SprocketControl SprocketControl = (SprocketControl)d; double oldInterval = (double)e.OldValue; double newInterval = SprocketControl.Interval; SprocketControl.OnIntervalChanged(oldInterval, newInterval); }