@@ -24,14 +24,14 @@ public partial class RingShape : Path
2424 protected virtual void OnStartAngleChanged ( double oldValue , double newValue )
2525 {
2626 BeginUpdate ( ) ;
27- ValidateAngle ( this , StartAngle , true ) ;
27+ StartAngle = ValidateAngle ( StartAngle ) ;
2828 EndUpdate ( ) ;
2929 }
3030
3131 protected virtual void OnEndAngleChanged ( double oldValue , double newValue )
3232 {
3333 BeginUpdate ( ) ;
34- ValidateAngle ( this , EndAngle , false ) ;
34+ EndAngle = ValidateAngle ( EndAngle ) ;
3535 EndUpdate ( ) ;
3636 }
3737
@@ -44,28 +44,28 @@ protected virtual void OnSweepDirectionChanged(SweepDirection oldValue, SweepDir
4444 protected virtual void OnMinAngleChanged ( double oldValue , double newValue )
4545 {
4646 BeginUpdate ( ) ;
47- CalculateAndSetNormalizedAngles ( this , MinAngle , MaxAngle ) ;
47+ CalculateAndSetNormalizedAngles ( ) ;
4848 EndUpdate ( ) ;
4949 }
5050
5151 protected virtual void OnMaxAngleChanged ( double oldValue , double newValue )
5252 {
5353 BeginUpdate ( ) ;
54- CalculateAndSetNormalizedAngles ( this , MinAngle , MaxAngle ) ;
54+ CalculateAndSetNormalizedAngles ( ) ;
5555 EndUpdate ( ) ;
5656 }
5757
5858 protected virtual void OnRadiusWidthChanged ( double oldValue , double newValue )
5959 {
6060 BeginUpdate ( ) ;
61- AdjustRadiusWidth ( this , RadiusWidth , StrokeThickness ) ;
61+ AdjustRadiusWidth ( ) ;
6262 EndUpdate ( ) ;
6363 }
6464
6565 protected virtual void OnRadiusHeightChanged ( double oldValue , double newValue )
6666 {
6767 BeginUpdate ( ) ;
68- AdjustRadiusHeight ( this , RadiusHeight , StrokeThickness ) ;
68+ AdjustRadiusHeight ( ) ;
6969 EndUpdate ( ) ;
7070 }
7171
@@ -74,5 +74,17 @@ protected virtual void OnIsCircleChanged(bool oldValue, bool newValue)
7474 BeginUpdate ( ) ;
7575 EndUpdate ( ) ;
7676 }
77+
78+ private void RingShape_SizeChanged ( object obj , SizeChangedEventArgs e )
79+ {
80+ BeginUpdate ( ) ;
81+ EndUpdate ( ) ;
82+ }
83+
84+ private void OnStrokeThicknessChanged ( DependencyObject d , DependencyProperty dp )
85+ {
86+ BeginUpdate ( ) ;
87+ EndUpdate ( ) ;
88+ }
7789 }
7890}
0 commit comments