Ejemplo n.º 1
0
 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);
         }
     }
 }
Ejemplo n.º 2
0
        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();
        }
Ejemplo n.º 3
0
 private static void IsActiveChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e)
 {
     //if(e.NewValue is bool)
     //    ring.IsVisible = (bool)e.NewValue;
     ring.UpdateActiveState();
 }
Ejemplo n.º 4
0
 private static void OnSizeChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e)
 {
     ring.SetValue(BindableWidthProperty, ring.Width);
 }
Ejemplo n.º 5
0
 private static void IsLargeChangedCallback(ProgressRing ring, AvaloniaPropertyChangedEventArgs e)
 {
     ring.UpdateLargeState();
 }
Ejemplo n.º 6
0
 private static void BindableWidthCallback(ProgressRing ring, AvaloniaPropertyChangedEventArgs e)
 {
     ring.SetEllipseDiameter((double)e.NewValue);
     ring.SetEllipseOffset((double)e.NewValue);
     ring.SetMaxSideLength((double)e.NewValue);
 }
Ejemplo n.º 7
0
 private static void IsActiveChanged(ProgressRing ring, AvaloniaPropertyChangedEventArgs e)
 {
     ring.UpdatePseudoClasses();
 }