コード例 #1
0
        /// <summary>
        /// Static class constructor
        /// </summary>
        static ULongUpDown()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(ULongUpDown),
                                                     new FrameworkPropertyMetadata(typeof(ULongUpDown)));

            MaxValueProperty.OverrideMetadata(typeof(ULongUpDown),
                                              new PropertyMetadata(ulong.MaxValue));

            MinValueProperty.OverrideMetadata(typeof(ULongUpDown),
                                              new PropertyMetadata(ulong.MinValue));

            // Override Min/Max default values
            ////            AbstractBaseUpDown<ulong>.MinValueProperty.OverrideMetadata(
            ////                typeof(ULongUpDown), new PropertyMetadata(ulong.MinValue));
            ////
            ////            AbstractBaseUpDown<ulong>.MaxValueProperty.OverrideMetadata(
            ////                typeof(ULongUpDown), new PropertyMetadata(ulong.MaxValue));
        }
コード例 #2
0
        /// <summary>
        /// Static class constructor
        /// </summary>
        static ShortUpDown()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(ShortUpDown),
                                                     new FrameworkPropertyMetadata(typeof(ShortUpDown)));

            MaxValueProperty.OverrideMetadata(typeof(ShortUpDown),
                                              new PropertyMetadata(short.MaxValue));

            MinValueProperty.OverrideMetadata(typeof(ShortUpDown),
                                              new PropertyMetadata(short.MinValue));

            // Override Min/Max default values
            ////            AbstractBaseUpDown<short>.MinValueProperty.OverrideMetadata(
            ////                typeof(ShortUpDown), new PropertyMetadata(short.MinValue));
            ////
            ////            AbstractBaseUpDown<short>.MaxValueProperty.OverrideMetadata(
            ////                typeof(ShortUpDown), new PropertyMetadata(short.MaxValue));
        }
コード例 #3
0
        /// <summary>
        /// Static class constructor
        /// </summary>
        static DecimalUpDown()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(DecimalUpDown),
                                                     new FrameworkPropertyMetadata(typeof(DecimalUpDown)));

            MaxValueProperty.OverrideMetadata(typeof(DecimalUpDown),
                                              new PropertyMetadata(decimal.MaxValue));

            MinValueProperty.OverrideMetadata(typeof(DecimalUpDown),
                                              new PropertyMetadata(decimal.MinValue));

            // Override Min/Max default values
            ////            AbstractBaseUpDown<decimal>.MinValueProperty.OverrideMetadata(
            ////                typeof(DecimalUpDown), new PropertyMetadata(decimal.MinValue));
            ////
            ////            AbstractBaseUpDown<decimal>.MaxValueProperty.OverrideMetadata(
            ////                typeof(DecimalUpDown), new PropertyMetadata(decimal.MaxValue));
        }
コード例 #4
0
        /// <summary>
        /// Static class constructor
        /// </summary>
        static FloatUpDown()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(FloatUpDown),
                                                     new FrameworkPropertyMetadata(typeof(FloatUpDown)));

            FormatStringProperty.OverrideMetadata(typeof(FloatUpDown),
                                                  new PropertyMetadata("F2"));

            MaxValueProperty.OverrideMetadata(typeof(FloatUpDown),
                                              new PropertyMetadata(float.MaxValue));

            MinValueProperty.OverrideMetadata(typeof(FloatUpDown),
                                              new PropertyMetadata(float.MinValue));

            // Override Min/Max default values
            ////            AbstractBaseUpDown<float>.MinValueProperty.OverrideMetadata(
            ////                typeof(FloatUpDown), new PropertyMetadata(float.MinValue));
            ////
            ////            AbstractBaseUpDown<float>.MaxValueProperty.OverrideMetadata(
            ////                typeof(FloatUpDown), new PropertyMetadata(float.MaxValue));
        }
コード例 #5
0
        /// <summary>
        /// Static class constructor
        /// </summary>
        static DoubleUpDown()
        {
            DefaultStyleKeyProperty.OverrideMetadata(typeof(DoubleUpDown),
                                                     new FrameworkPropertyMetadata(typeof(DoubleUpDown)));

            // overide default values inherited dependency properties
            FormatStringProperty.OverrideMetadata(typeof(DoubleUpDown),
                                                  new PropertyMetadata("F2"));

            MaxValueProperty.OverrideMetadata(typeof(DoubleUpDown),
                                              new PropertyMetadata(double.MaxValue));

            MinValueProperty.OverrideMetadata(typeof(DoubleUpDown),
                                              new PropertyMetadata(double.MinValue));

            // Override Min/Max default values
            ////            AbstractBaseUpDown<double>.MinValueProperty.OverrideMetadata(
            ////                typeof(DoubleUpDown), new PropertyMetadata(double.MinValue));
            ////
            ////            AbstractBaseUpDown<double>.MaxValueProperty.OverrideMetadata(
            ////                typeof(DoubleUpDown), new PropertyMetadata(double.MaxValue));
        }