private static void IsVisibleChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { if (e.NewValue != e.OldValue) { if ((bool)e.NewValue == false) { ring.SetValue(ProgressRing.IsActiveProperty, false); } else { ring.SetValue(ProgressRing.IsActiveProperty, true); } } }
private static void BindableWidthCallback(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { //var action = new Action(() => //{ ring.SetEllipseDiameter((double)e.NewValue); ring.SetEllipseOffset((double)e.NewValue); ring.SetMaxSideLength((double)e.NewValue); //}); //if (ring._deferredActions != null) // ring._deferredActions.Add(action); //else // action(); }
private static void IsActiveChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { //if(e.NewValue is bool) // ring.IsVisible = (bool)e.NewValue; ring.UpdateActiveState(); }
private static void OnSizeChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { ring.SetValue(BindableWidthProperty, ring.Width); }
private static void IsLargeChangedCallback(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { ring.UpdateLargeState(); }
private static void BindableWidthCallback(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { ring.SetEllipseDiameter((double)e.NewValue); ring.SetEllipseOffset((double)e.NewValue); ring.SetMaxSideLength((double)e.NewValue); }
private static void IsActiveChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e) { ring.UpdatePseudoClasses(); }