diff --git a/src/Shared/HandyControlDemo_Shared/UserControl/Controls/TextBoxDemo.xaml b/src/Shared/HandyControlDemo_Shared/UserControl/Controls/TextBoxDemo.xaml index 080d7fb6..e313be35 100644 --- a/src/Shared/HandyControlDemo_Shared/UserControl/Controls/TextBoxDemo.xaml +++ b/src/Shared/HandyControlDemo_Shared/UserControl/Controls/TextBoxDemo.xaml @@ -8,42 +8,123 @@ DataContext="{Binding InputElementDemo, Source={StaticResource Locator}}"> - + - - + + - - - + + + - + - + + + + + + + + + + + + - - - - + + - - - + + + - + - + + + + + + + + + + + + - - diff --git a/src/Shared/HandyControlDemo_Shared/UserControl/Styles/NativeTextBoxDemo.xaml b/src/Shared/HandyControlDemo_Shared/UserControl/Styles/NativeTextBoxDemo.xaml index 76f78330..620be1e1 100644 --- a/src/Shared/HandyControlDemo_Shared/UserControl/Styles/NativeTextBoxDemo.xaml +++ b/src/Shared/HandyControlDemo_Shared/UserControl/Styles/NativeTextBoxDemo.xaml @@ -4,29 +4,124 @@ xmlns:hc="https://handyorg.github.io/handycontrol" xmlns:langs="clr-namespace:HandyControlDemo.Properties.Langs" xmlns:ex="clr-namespace:HandyControlDemo.Tools.Extension" - Background="{DynamicResource RegionBrush}"> + Background="{DynamicResource RegionBrush}" + DataContext="{Binding InputElementDemo, Source={StaticResource Locator}}"> - + - - + + - - - - - + + + + + + + + + + + + + + + + + + + + + + - - + + - - - - - + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/Shared/HandyControlDemo_Shared/ViewModel/Common/InputElementDemoViewModel.cs b/src/Shared/HandyControlDemo_Shared/ViewModel/Common/InputElementDemoViewModel.cs index 50fbc5d0..f5135270 100644 --- a/src/Shared/HandyControlDemo_Shared/ViewModel/Common/InputElementDemoViewModel.cs +++ b/src/Shared/HandyControlDemo_Shared/ViewModel/Common/InputElementDemoViewModel.cs @@ -13,6 +13,8 @@ public class InputElementDemoViewModel : ViewModelBase { private string _email1; private string _email2; + private string _text1; + private string _text2; private double _doubleValue1; private double _doubleValue2; private IList _dataList; @@ -38,6 +40,26 @@ public class InputElementDemoViewModel : ViewModelBase #endif } + public string Text1 + { + get => _text1; +#if NET40 + set => Set(nameof(Text1), ref _text1, value); +#else + set => Set(ref _text1, value); +#endif + } + + public string Text2 + { + get => _text2; +#if NET40 + set => Set(nameof(Text2), ref _text2, value); +#else + set => Set(ref _text2, value); +#endif + } + public double DoubleValue1 { get => _doubleValue1;