Exemplo n.º 1
0
        /// <summary>
        ///     Called when MinimumProperty is changed on "d."
        /// </summary>
        private static void OnMaximumChanged(DependencyObject d, DependencyPropertyChangedEventArgs e)
        {
            RangePanel pan = (RangePanel)d;

            //  pan.CoerceValue(MinimumProperty);
            pan.OnMaximumChanged((double)e.OldValue, (double)e.NewValue);
        }
Exemplo n.º 2
0
        private static object CoerceMaximum(DependencyObject d, object value)
        {
            RangePanel pan = (RangePanel)d;
            double     min = pan.Minimum;

            if ((double)value < min)
            {
                return(min);
            }
            return(value);
        }