@@ -23,42 +23,58 @@ public partial class RingShape : Path
2323 {
2424 protected virtual void OnStartAngleChanged ( double oldValue , double newValue )
2525 {
26- StartAngleChanged ( ) ;
26+ BeginUpdate ( ) ;
27+ ValidateAngle ( this , StartAngle , true ) ;
28+ EndUpdate ( ) ;
2729 }
2830
2931 protected virtual void OnEndAngleChanged ( double oldValue , double newValue )
3032 {
31- EndAngleChanged ( ) ;
33+ BeginUpdate ( ) ;
34+ ValidateAngle ( this , EndAngle , false ) ;
35+ EndUpdate ( ) ;
3236 }
3337
3438 protected virtual void OnSweepDirectionChanged ( SweepDirection oldValue , SweepDirection newValue )
3539 {
36- SweepDirectionChanged ( ) ;
40+ BeginUpdate ( ) ;
41+ _sweepDirection = SweepDirection ;
42+ EndUpdate ( ) ;
3743 }
3844
3945 protected virtual void OnMinAngleChanged ( double oldValue , double newValue )
4046 {
41- MinMaxAngleChanged ( false ) ;
47+ BeginUpdate ( ) ;
48+ CalculateAndSetNormalizedAngles ( this , MinAngle , MaxAngle ) ;
49+ EndUpdate ( ) ;
4250 }
4351
4452 protected virtual void OnMaxAngleChanged ( double oldValue , double newValue )
4553 {
46- MinMaxAngleChanged ( true ) ;
54+ BeginUpdate ( ) ;
55+ CalculateAndSetNormalizedAngles ( this , MinAngle , MaxAngle ) ;
56+ EndUpdate ( ) ;
4757 }
4858
4959 protected virtual void OnRadiusWidthChanged ( double oldValue , double newValue )
5060 {
51- RadiusWidthChanged ( ) ;
61+ BeginUpdate ( ) ;
62+ AdjustRadiusWidth ( this , RadiusWidth , StrokeThickness ) ;
63+ EndUpdate ( ) ;
5264 }
5365
5466 protected virtual void OnRadiusHeightChanged ( double oldValue , double newValue )
5567 {
56- RadiusHeightChanged ( ) ;
68+ BeginUpdate ( ) ;
69+ AdjustRadiusHeight ( this , RadiusHeight , StrokeThickness ) ;
70+ EndUpdate ( ) ;
5771 }
5872
5973 protected virtual void OnIsCircleChanged ( bool oldValue , bool newValue )
6074 {
61- IsCircleChanged ( ) ;
75+ BeginUpdate ( ) ;
76+ _isCircle = IsCircle ;
77+ EndUpdate ( ) ;
6278 }
6379 }
6480}
0 commit comments