19 overrides of DefaultAction
System.Windows.Forms (18)
System\Windows\Forms\Accessibility\Control.ControlAccessibleObject.cs (1)
200public override string? DefaultAction => Owner?.AccessibleDefaultActionDescription ?? base.DefaultAction;
System\Windows\Forms\Controls\ComboBox\ComboBox.ComboBoxChildDropDownButtonUiaProvider.cs (1)
46public override string? DefaultAction => GetDefaultActionInternal().ToNullableStringAndFree();
System\Windows\Forms\Controls\ComboBox\ComboBox.ComboBoxItemAccessibleObject.cs (1)
59public override string? DefaultAction => GetDefaultActionInternal().ToNullableStringAndFree();
System\Windows\Forms\Controls\DataGridView\DataGridViewCell.DataGridViewCellAccessibleObject.cs (1)
32public override string DefaultAction
System\Windows\Forms\Controls\Labels\LinkLabel.Link.LinkAccessibleObject.cs (1)
60public override string DefaultAction => SR.AccessibleActionClick;
System\Windows\Forms\Controls\ListBoxes\ListBox.ItemAccessibleObject.cs (1)
83public override string? DefaultAction => GetDefaultActionInternal().ToNullableStringAndFree();
System\Windows\Forms\Controls\ListView\ListViewGroup.ListViewGroupAccessibleObject.cs (1)
88public override string DefaultAction => SR.AccessibleActionDoubleClick;
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemBaseAccessibleObject.cs (1)
99public override string DefaultAction
System\Windows\Forms\Controls\ListView\ListViewItem.ListViewItemImageAccessibleObject.cs (1)
30public override string DefaultAction => string.Empty;
System\Windows\Forms\Controls\MonthCalendar\MonthCalendar.CalendarButtonAccessibleObject.cs (1)
26public override string DefaultAction => SR.AccessibleActionClick;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridEntry.GridEntryAccessibleObject.cs (1)
33public override string? DefaultAction
System\Windows\Forms\Controls\TabControl\TabPage.TabAccessibleObject.cs (1)
45public override string? DefaultAction => GetDefaultActionInternal().ToNullableStringAndFree();
System\Windows\Forms\Controls\ToolStrips\ToolStripItem.ToolStripItemAccessibleObject.cs (1)
30public override string DefaultAction
System\Windows\Forms\Controls\TrackBar\TrackBar.TrackBarFirstButtonAccessibleObject.cs (1)
15public override string DefaultAction => SR.AccessibleActionPress;
System\Windows\Forms\Controls\TrackBar\TrackBar.TrackBarLastButtonAccessibleObject.cs (1)
15public override string DefaultAction => SR.AccessibleActionPress;
System\Windows\Forms\Controls\TreeView\TreeNode.TreeNodeAccessibleObject.cs (1)
36public override string DefaultAction
System\Windows\Forms\Controls\UpDown\UpDownBase.UpDownButtons.UpDownButtonsAccessibleObject.DirectionButtonAccessibleObject.cs (1)
50public override string DefaultAction => SR.AccessibleActionPress;
System\Windows\Forms\Scrolling\ScrollBar.ScrollBarChildAccessibleObject.cs (1)
37public override string? DefaultAction => GetDefaultActionInternal().ToNullableStringAndFree();
System.Windows.Forms.Design (1)
System\Windows\Forms\Design\ControlDesigner.ControlDesignerAccessibleObject.cs (1)
30public override string DefaultAction => string.Empty;
76 references to DefaultAction
System.Windows.Forms (9)
System\Windows\Forms\Accessibility\AccessibleObject.cs (7)
152/// Determines if <see cref="GetDefaultActionInternal"/> can be called without calling <see cref="DefaultAction"/> 638UIA_PROPERTY_ID.UIA_LegacyIAccessibleDefaultActionPropertyId => !string.IsNullOrEmpty(DefaultAction) ? (VARIANT)DefaultAction : VARIANT.Empty, 695_ => !string.IsNullOrEmpty(DefaultAction), 1302*pszDefaultAction = new(DefaultAction); 1954: new(DefaultAction); 1964: new(child.DefaultAction);
System\Windows\Forms\Accessibility\Control.ControlAccessibleObject.cs (1)
200public override string? DefaultAction => Owner?.AccessibleDefaultActionDescription ?? base.DefaultAction;
System\Windows\Forms\Controls\PropertyGrid\PropertyGridInternal\GridEntry.GridEntryAccessibleObject.cs (1)
39return base.DefaultAction;
System.Windows.Forms.Tests (65)
System\Windows\Forms\AccessibleObjects\AccessibleObjectTests.cs (17)
22Assert.Null(accessibleObject.DefaultAction); 617Assert.Null(accessibleObject.DefaultAction); 636Assert.Null(accessibleObject.DefaultAction); 657Assert.Null(accessibleObject.DefaultAction); 683Assert.Null(accessibleObject.DefaultAction); 702Assert.Null(accessibleObject.DefaultAction); 721Assert.Null(accessibleObject.DefaultAction); 740Assert.Null(accessibleObject.DefaultAction); 761Assert.Null(accessibleObject.DefaultAction); 782Assert.Null(accessibleObject.DefaultAction); 803Assert.Null(accessibleObject.DefaultAction); 1517.Setup(a => a.DefaultAction) 1525mockAccessibleObject.Verify(a => a.DefaultAction, Times.Once()); 1539.Setup(a => a.DefaultAction) 1547.Setup(a => a.DefaultAction) 1570mockAccessibleObjectChild1.Verify(a => a.DefaultAction, Times.Exactly(child1CallCount)); 1571mockAccessibleObjectChild2.Verify(a => a.DefaultAction, Times.Exactly(child2CallCount));
System\Windows\Forms\AccessibleObjects\CheckBox.CheckBoxAccessibleObjectTests.cs (4)
48checkBox.AccessibilityObject.DefaultAction.Should().Be("TestActionDescription"); 58checkBox.AccessibilityObject.DefaultAction.Should().Be("Check"); 62checkBox.AccessibilityObject.DefaultAction.Should().Be("Uncheck"); 303Assert.Equal(checkBox.AccessibilityObject.DefaultAction, ((BSTR)checkBox.AccessibilityObject.GetPropertyValue(UIA_PROPERTY_ID.UIA_LegacyIAccessibleDefaultActionPropertyId)).ToStringAndFree());
System\Windows\Forms\AccessibleObjects\CheckedListBoxItemAccessibleObjectTests.cs (2)
170Assert.Equal(string.Empty, checkedListBox.AccessibilityObject.GetChild(0).DefaultAction); 189Assert.Equal(expected, checkedListBox.AccessibilityObject.GetChild(0).DefaultAction);
System\Windows\Forms\AccessibleObjects\ComboBox.ComboBoxAccessibleObjectTests.cs (4)
311Assert.Equal(comboBox.AccessibleDefaultActionDescription, comboBox.AccessibilityObject.DefaultAction); 320Assert.Empty(comboBox.AccessibilityObject.DefaultAction); 331Assert.Empty(comboBox.AccessibilityObject.DefaultAction); 351Assert.Equal(expectedAction, comboBox.AccessibilityObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\DataGridViewCellAccessibleObjectTests.cs (2)
147Assert.Equal(expected, accessibleObject.DefaultAction); 168Assert.Throws<InvalidOperationException>(() => accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\DataGridViewCheckBoxCellAccessibleObjectTests.cs (1)
118Assert.Equal(string.Empty, cell.AccessibilityObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\DataGridViewRowAccessibleObjectTests.cs (2)
19Assert.Null(accessibleObject.DefaultAction); 37Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\DataGridViewTopLeftHeaderCellAccessibleObjectTests.cs (1)
76Assert.Equal(expected, cell.AccessibilityObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\DateTimePicker.DateTimePickerAccessibleObjectTests.cs (1)
317Assert.Equal(expected, accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\HScrollBar.ScrollBarFirstLineButtonAccessibleObjectTests.cs (2)
44Assert.Null(accessibleObject.DefaultAction); 55Assert.NotNull(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\HScrollBar.ScrollBarFirstPageButtonAccessibleObjectTests.cs (2)
66Assert.NotEmpty(accessibleObject.DefaultAction); 77Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\HScrollBar.ScrollBarLastLineButtonAccessibleObjectTests.cs (2)
44Assert.NotEmpty(accessibleObject.DefaultAction); 55Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\HScrollBar.ScrollBarLastPageButtonAccessibleObjectTests.cs (2)
55Assert.NotEmpty(accessibleObject.DefaultAction); 66Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\HScrollBar.ScrollBarThumbAccessibleObjectTests.cs (1)
44Assert.Equal(string.Empty, accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\ListBox.ListBoxItemAccessibleObjectTests.cs (1)
181itemAccessibleObject.DefaultAction.Should().NotBeNull();
System\Windows\Forms\AccessibleObjects\ListViewItem.ListViewItemBaseAccessibleObjectTests.cs (1)
326Assert.Equal(itemIsChecked ? SR.AccessibleActionUncheck : SR.AccessibleActionCheck, itemAccessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\MonthCalendar.CalendarButtonAccessibleObjectTests.cs (1)
32Assert.Equal(SR.AccessibleActionClick, buttonAccessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\MonthCalendar.CalendarDayOfWeekCellAccessibleObjectTests.cs (1)
47Assert.Empty(cellAccessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\MonthCalendar.CalendarWeekNumberCellAccessibleObjectTests.cs (1)
39Assert.Empty(cellAccessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\TabPage.TabAccessibleObjectTests.cs (2)
77Assert.Null(accessibleObject.DefaultAction); 92Assert.NotEmpty(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\ToolStripScrollButton.ToolStripScrollButtonAccessibleObjectTests.cs (2)
151Assert.Equal(expectedDefaultAction, upScrollButtonAccessibleObject.DefaultAction); 155Assert.Equal(expectedDefaultAction, downScrollButtonAccessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\TrackBar.TrackBarAccessibleObjectTests.cs (1)
317Assert.Equal(defaultAction, trackBar.AccessibilityObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\TrackBar.TrackBarFirstButtonAccessibleObjectTests.cs (1)
52Assert.Equal(SR.AccessibleActionPress, accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\TrackBar.TrackBarLastButtonAccessibleObjectTests.cs (1)
52Assert.Equal(SR.AccessibleActionPress, accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\TrackBar.TrackBarThumbAccessibleObjectTests.cs (1)
41Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\VScrollBar.ScrollBarFirstLineButtonAccessibleObjectTests.cs (2)
44Assert.Null(accessibleObject.DefaultAction); 55Assert.NotNull(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\VScrollBar.ScrollBarFirstPageButtonAccessibleObjectTests.cs (2)
66Assert.NotEmpty(accessibleObject.DefaultAction); 77Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\VScrollBar.ScrollBarLastLineButtonAccessibleObjectTests.cs (2)
44Assert.NotEmpty(accessibleObject.DefaultAction); 55Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\VScrollBar.ScrollBarLastPageButtonAccessibleObjectTests.cs (2)
55Assert.NotEmpty(accessibleObject.DefaultAction); 66Assert.Null(accessibleObject.DefaultAction);
System\Windows\Forms\AccessibleObjects\VScrollBar.ScrollBarThumbAccessibleObjectTests.cs (1)
44Assert.Equal(string.Empty, accessibleObject.DefaultAction);
System.Windows.Forms.UI.IntegrationTests (2)
ListBoxItemAccessibleObjestTests.cs (2)
42itemAccessibleObjectDoubleClick.DefaultAction.Should().Be("Double Click"); 46itemAccessibleObjectNullAction.DefaultAction.Should().BeNull();