diff --git a/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Implementation/CalculatorUpDown.cs b/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Implementation/CalculatorUpDown.cs index 2e6dd5fe..237f990f 100644 --- a/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Implementation/CalculatorUpDown.cs +++ b/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Implementation/CalculatorUpDown.cs @@ -16,6 +16,17 @@ namespace Microsoft.Windows.Controls #region Properties + #region DisplayText + + public static readonly DependencyProperty DisplayTextProperty = DependencyProperty.Register("DisplayText", typeof(string), typeof(CalculatorUpDown), new UIPropertyMetadata("0")); + public string DisplayText + { + get { return (string)GetValue(DisplayTextProperty); } + set { SetValue(DisplayTextProperty, value); } + } + + #endregion //DisplayText + #region EnterClosesCalculator public static readonly DependencyProperty EnterClosesCalculatorProperty = DependencyProperty.Register("EnterClosesCalculator", typeof(bool), typeof(CalculatorUpDown), new UIPropertyMetadata(false)); @@ -50,6 +61,28 @@ namespace Microsoft.Windows.Controls #endregion //IsOpen + #region Memory + + public static readonly DependencyProperty MemoryProperty = DependencyProperty.Register("Memory", typeof(decimal), typeof(CalculatorUpDown), new UIPropertyMetadata(default(decimal))); + public decimal Memory + { + get { return (decimal)GetValue(MemoryProperty); } + set { SetValue(MemoryProperty, value); } + } + + #endregion //Memory + + #region Precision + + public static readonly DependencyProperty PrecisionProperty = DependencyProperty.Register("Precision", typeof(int), typeof(CalculatorUpDown), new UIPropertyMetadata(6)); + public int Precision + { + get { return (int)GetValue(PrecisionProperty); } + set { SetValue(PrecisionProperty, value); } + } + + #endregion //Precision + #endregion //Properties #region Constructors diff --git a/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml b/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml index 95bf8f6d..eb1edc87 100644 --- a/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml +++ b/ExtendedWPFToolkitSolution/Src/WPFToolkit.Extended/CalculatorUpDown/Themes/Generic.xaml @@ -101,7 +101,11 @@ - +