Ejemplo n.º 1
0
        private static void OnSpeedRatioChangedCallback(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            LoadingIndicator indicator = d as LoadingIndicator;

            if (indicator.PART_Root == null || !indicator.IsActived)
            {
                return;
            }
            indicator.SetSpeedRatio(indicator.PART_Root, indicator.SpeedRatio);
        }
Ejemplo n.º 2
0
        private static void OnIsActivedChangedCallback(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            LoadingIndicator indicator = d as LoadingIndicator;

            if (indicator.PART_Root == null)
            {
                return;
            }

            VisualStateManager.GoToElementState(indicator.PART_Root, (bool)e.NewValue ? "Active" : "Inactive", true);
        }