Example #1
0
        private static void PercentageChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            SliderGauge g = d as SliderGauge;

            g.m_percentage = g.CoercePercentage((double)e.NewValue);
            g.UpdateVisuals();
        }
Example #2
0
        private static void OrientationChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            SliderGauge g = d as SliderGauge;

            if (g != null)
            {
                g.UpdateVisuals();
            }
        }
Example #3
0
        private static void PercentageChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            SliderGauge g = d as SliderGauge;

            if (g != null)
            {
                if (g.m_percentageTextBlock != null)
                {
                    g.m_percentageTextBlock.Text = g.Percentage.ToString("p0");
                }
                g.UpdateVisuals();
            }
        }