예제 #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();
        }