diff options
author | Jimmy Garrido <jimmygarrido@outlook.com> | 2016-10-11 11:59:41 -0700 |
---|---|---|
committer | Stephane Delcroix <stephane@delcroix.org> | 2016-10-11 20:59:41 +0200 |
commit | caa3816b0c19029be200ce422da19162e85ffc5b (patch) | |
tree | 0418a9124aa9dfa74dbd489ba8ef8384298135bb /Xamarin.Forms.Platform.WinRT | |
parent | 44397cb57df3a94e0265ab94619e4aa18e1da46b (diff) | |
download | xamarin-forms-caa3816b0c19029be200ce422da19162e85ffc5b.tar.gz xamarin-forms-caa3816b0c19029be200ce422da19162e85ffc5b.tar.bz2 xamarin-forms-caa3816b0c19029be200ce422da19162e85ffc5b.zip |
[Windows] Fix crash when toggling IsPassword on multiple Entry controls (#405)
* [Windows] Fix crash when toggling IsPassword on multiple Entry controls
Diffstat (limited to 'Xamarin.Forms.Platform.WinRT')
-rw-r--r-- | Xamarin.Forms.Platform.WinRT/FormsTextBox.cs | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Xamarin.Forms.Platform.WinRT/FormsTextBox.cs b/Xamarin.Forms.Platform.WinRT/FormsTextBox.cs index 4cb74ec7..5847e0b9 100644 --- a/Xamarin.Forms.Platform.WinRT/FormsTextBox.cs +++ b/Xamarin.Forms.Platform.WinRT/FormsTextBox.cs @@ -37,7 +37,7 @@ namespace Xamarin.Forms.Platform.WinRT public new static readonly DependencyProperty TextProperty = DependencyProperty.Register(nameof(Text), typeof(string), typeof(FormsTextBox), new PropertyMetadata("", TextPropertyChanged)); - static InputScope s_passwordInputScope; + InputScope passwordInputScope; Border _borderElement; InputScope _cachedInputScope; bool _cachedPredictionsSetting; @@ -87,20 +87,20 @@ namespace Xamarin.Forms.Platform.WinRT set { SetValue(TextProperty, value); } } - static InputScope PasswordInputScope + InputScope PasswordInputScope { get { - if (s_passwordInputScope != null) + if (passwordInputScope != null) { - return s_passwordInputScope; + return passwordInputScope; } - s_passwordInputScope = new InputScope(); + passwordInputScope = new InputScope(); var name = new InputScopeName { NameValue = InputScopeNameValue.Default }; - s_passwordInputScope.Names.Add(name); + passwordInputScope.Names.Add(name); - return s_passwordInputScope; + return passwordInputScope; } } |