diff options
-rwxr-xr-x[-rw-r--r--] | Xamarin.PropertyEditing.Windows/ComboBoxEx.cs | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/Xamarin.PropertyEditing.Windows/ComboBoxEx.cs b/Xamarin.PropertyEditing.Windows/ComboBoxEx.cs index a66d18c..6d9bd3f 100644..100755 --- a/Xamarin.PropertyEditing.Windows/ComboBoxEx.cs +++ b/Xamarin.PropertyEditing.Windows/ComboBoxEx.cs @@ -1,4 +1,5 @@ using System.Windows; +using System.Windows.Automation; using System.Windows.Automation.Peers; using System.Windows.Controls; using System.Windows.Input; @@ -27,6 +28,18 @@ namespace Xamarin.PropertyEditing.Windows return new ComboBoxExAutomationPeer (this); } + public override void OnApplyTemplate () + { + base.OnApplyTemplate (); + + var textBox = Template.FindName ("PART_EditableTextBox", this) as TextBox; + if (textBox != null) { + string accessibilityName = AutomationProperties.GetName (this); + + AutomationProperties.SetName (textBox, accessibilityName); + } + } + protected override void OnSelectionChanged (SelectionChangedEventArgs e) { base.OnSelectionChanged (e); |