Пример #1
0
        public MainPage()
        {
            this.InitializeComponent();

            // ACCESSIBILITY BUG FIX:
            // Set the descriptive information on the phone field from the nearby error string.
            var describedBy = AutomationProperties.GetDescribedBy(PhoneField);

            describedBy.Add(PhoneFieldDescription);
        }
Пример #2
0
        public MainPage()
        {
            this.InitializeComponent();

            // Have the CheckBox described by a nearby TextBlock.
            var describedBy = AutomationProperties.GetDescribedBy(PreloadCheckBox);
            describedBy.Add(PreloadDescriptionTB);

            var saladDescribedBy = AutomationProperties.GetDescribedBy(IncludeSaladCheckBox);
            saladDescribedBy.Add(IncludeSaladDescriptionTB);
        }
Пример #3
0
        private void ClearButton_Click(object sender, RoutedEventArgs e)
        {
            NameField.Text  = "";
            PhoneField.Text = "";
            EmailField.Text = "";

            PhoneFieldDescription.Visibility = Visibility.Collapsed;

            var describedBy = AutomationProperties.GetDescribedBy(PhoneField);

            describedBy.Clear();
        }