summaryrefslogtreecommitdiff
path: root/Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs')
-rw-r--r--Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs40
1 files changed, 20 insertions, 20 deletions
diff --git a/Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs b/Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs
index 778f464e..82266883 100644
--- a/Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs
+++ b/Xamarin.Forms.Platform.WinRT/VisualElementRenderer.cs
@@ -301,13 +301,13 @@ namespace Xamarin.Forms.Platform.WinRT
UpdateEnabled();
else if (e.PropertyName == VisualElement.BackgroundColorProperty.PropertyName)
UpdateBackgroundColor();
- else if (e.PropertyName == Accessibility.HintProperty.PropertyName)
+ else if (e.PropertyName == AutomationProperties.HelpTextProperty.PropertyName)
SetAutomationPropertiesHelpText();
- else if (e.PropertyName == Accessibility.NameProperty.PropertyName)
+ else if (e.PropertyName == AutomationProperties.NameProperty.PropertyName)
SetAutomationPropertiesName();
- else if (e.PropertyName == Accessibility.IsInAccessibleTreeProperty.PropertyName)
+ else if (e.PropertyName == AutomationProperties.IsInAccessibleTreeProperty.PropertyName)
SetAutomationPropertiesAccessibilityView();
- else if (e.PropertyName == Accessibility.LabeledByProperty.PropertyName)
+ else if (e.PropertyName == AutomationProperties.LabeledByProperty.PropertyName)
SetAutomationPropertiesLabeledBy();
}
@@ -319,7 +319,7 @@ namespace Xamarin.Forms.Platform.WinRT
protected virtual void SetAutomationId(string id)
{
- SetValue(AutomationProperties.AutomationIdProperty, id);
+ SetValue(Windows.UI.Xaml.Automation.AutomationProperties.AutomationIdProperty, id);
}
protected virtual void SetAutomationPropertiesName()
@@ -328,14 +328,14 @@ namespace Xamarin.Forms.Platform.WinRT
return;
if (_defaultAutomationPropertiesName == null)
- _defaultAutomationPropertiesName = (string)Control.GetValue(AutomationProperties.NameProperty);
+ _defaultAutomationPropertiesName = (string)Control.GetValue(Windows.UI.Xaml.Automation.AutomationProperties.NameProperty);
- var elemValue = (string)Element.GetValue(Accessibility.NameProperty);
+ var elemValue = (string)Element.GetValue(AutomationProperties.NameProperty);
if (!string.IsNullOrWhiteSpace(elemValue))
- Control.SetValue(AutomationProperties.NameProperty, elemValue);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.NameProperty, elemValue);
else
- Control.SetValue(AutomationProperties.NameProperty, _defaultAutomationPropertiesName);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.NameProperty, _defaultAutomationPropertiesName);
}
protected virtual void SetAutomationPropertiesAccessibilityView()
@@ -344,17 +344,17 @@ namespace Xamarin.Forms.Platform.WinRT
return;
if (!_defaultAutomationPropertiesAccessibilityView.HasValue)
- _defaultAutomationPropertiesAccessibilityView = (AccessibilityView)Control.GetValue(AutomationProperties.AccessibilityViewProperty);
+ _defaultAutomationPropertiesAccessibilityView = (AccessibilityView)Control.GetValue(Windows.UI.Xaml.Automation.AutomationProperties.AccessibilityViewProperty);
var newValue = _defaultAutomationPropertiesAccessibilityView;
- var elemValue = (bool?)Element.GetValue(Accessibility.IsInAccessibleTreeProperty);
+ var elemValue = (bool?)Element.GetValue(AutomationProperties.IsInAccessibleTreeProperty);
if (elemValue == true)
newValue = AccessibilityView.Content;
else if (elemValue == false)
newValue = AccessibilityView.Raw;
- Control.SetValue(AutomationProperties.AccessibilityViewProperty, newValue);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.AccessibilityViewProperty, newValue);
}
protected virtual void SetAutomationPropertiesHelpText()
@@ -363,14 +363,14 @@ namespace Xamarin.Forms.Platform.WinRT
return;
if (_defaultAutomationPropertiesHelpText == null)
- _defaultAutomationPropertiesHelpText = (string)Control.GetValue(AutomationProperties.HelpTextProperty);
+ _defaultAutomationPropertiesHelpText = (string)Control.GetValue(Windows.UI.Xaml.Automation.AutomationProperties.HelpTextProperty);
- var elemValue = (string)Element.GetValue(Accessibility.HintProperty);
+ var elemValue = (string)Element.GetValue(AutomationProperties.HelpTextProperty);
if (!string.IsNullOrWhiteSpace(elemValue))
- Control.SetValue(AutomationProperties.HelpTextProperty, elemValue);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.HelpTextProperty, elemValue);
else
- Control.SetValue(AutomationProperties.HelpTextProperty, _defaultAutomationPropertiesHelpText);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.HelpTextProperty, _defaultAutomationPropertiesHelpText);
}
protected virtual void SetAutomationPropertiesLabeledBy()
@@ -379,16 +379,16 @@ namespace Xamarin.Forms.Platform.WinRT
return;
if (_defaultAutomationPropertiesLabeledBy == null)
- _defaultAutomationPropertiesLabeledBy = (UIElement)Control.GetValue(AutomationProperties.LabeledByProperty);
+ _defaultAutomationPropertiesLabeledBy = (UIElement)Control.GetValue(Windows.UI.Xaml.Automation.AutomationProperties.LabeledByProperty);
- var elemValue = (VisualElement)Element.GetValue(Accessibility.LabeledByProperty);
+ var elemValue = (VisualElement)Element.GetValue(AutomationProperties.LabeledByProperty);
var renderer = elemValue?.GetOrCreateRenderer();
var nativeElement = renderer?.GetNativeElement();
if (nativeElement != null)
- Control.SetValue(AutomationProperties.LabeledByProperty, nativeElement);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.LabeledByProperty, nativeElement);
else
- Control.SetValue(AutomationProperties.LabeledByProperty, _defaultAutomationPropertiesLabeledBy);
+ Control.SetValue(Windows.UI.Xaml.Automation.AutomationProperties.LabeledByProperty, _defaultAutomationPropertiesLabeledBy);
}
protected void SetNativeControl(TNativeElement control)