File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -83,11 +83,6 @@ public uint Value
8383 }
8484 } ;
8585
86- static ColorPicker ( )
87- {
88- ValueProperty . Changed . AddClassHandler < ColorPicker > ( ( c , _ ) => c . UpdateColors ( ) ) ;
89- }
90-
9186 public override void Render ( DrawingContext context )
9287 {
9388 base . Render ( context ) ;
Original file line number Diff line number Diff line change @@ -54,10 +54,12 @@ public bool IsExpanded
5454 set => SetValue ( IsExpandedProperty , value ) ;
5555 }
5656
57- static RevisionTreeNodeIcon ( )
57+ protected override void OnPropertyChanged ( AvaloniaPropertyChangedEventArgs change )
5858 {
59- NodeProperty . Changed . AddClassHandler < RevisionTreeNodeIcon > ( ( icon , _ ) => icon . UpdateContent ( ) ) ;
60- IsExpandedProperty . Changed . AddClassHandler < RevisionTreeNodeIcon > ( ( icon , _ ) => icon . UpdateContent ( ) ) ;
59+ base . OnPropertyChanged ( change ) ;
60+
61+ if ( change . Property == NodeProperty || change . Property == IsExpandedProperty )
62+ UpdateContent ( ) ;
6163 }
6264
6365 private void UpdateContent ( )
You can’t perform that action at this time.
0 commit comments