-
Notifications
You must be signed in to change notification settings - Fork 1.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Implementing HeadingLevel and IsDialog automation properties (#4751)
* Felipe coworking session for new UIAutomation property investigation * adding None as the default result * adding apicompat changes * Coworking session with Felipe: adding OS checks for new automation properties * Fix reference assemblies * Changing HeadingLevel enum to be in the correct way * adding isdialog implementation * changing to isdialog from getisdialog * improving isdialog implementation * Update src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/Automation/AutomationProperties.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * Update src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationClient/System/Windows/Automation/AutomationElement.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * Update src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationTypes/System/Windows/Automation/AutomationElementIdentifiers.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * Update src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/Automation/Peers/AutomationPeer.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * Update src/Microsoft.DotNet.Wpf/src/UIAutomation/UIAutomationTypes/System/Windows/Automation/AutomationElementIdentifiers.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * Update src/Microsoft.DotNet.Wpf/src/Shared/System/Windows/InterOp/OSVersionHelper.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * adding headinglevel summary * removing empty lines and adding description * Update src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/Automation/Peers/AutomationPeer.cs Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> * Update src/Microsoft.DotNet.Wpf/src/PresentationCore/System/Windows/Automation/Peers/AutomationPeer.cs Co-authored-by: Sam Bent <sambent@microsoft.com> * suggested changes * removing unecessary comment and adding rs5 for isDialog * changing enum constant * Adding window isdialogcore implementation * overriding headinglevelcore in peers * editing override of isdialog * changing values of enum for heading level so it correctly show in accessibility insights * changing IsDialogCore() to virtual * adding prefix in automation properties * changing location of automationheadinglevel.cs to fix api compat errors * updating presentationcore return types for heading level * Revert "changing location of automationheadinglevel.cs to fix api compat errors" This reverts commit 0afb956, as it creates some problems when running wpf * maintaining the values of the enum as this for further testing * Update src/Microsoft.DotNet.Wpf/src/PresentationFramework/System/Windows/Automation/Peers/WindowAutomationPeer.cs Co-authored-by: Sam Bent <sambent@microsoft.com> * changing enums to start on 0 and fixing automaticalli added code * first try to add enum mapping * removing unreachable code * moving the headinglevel conversion to automarionpeer.cs * removing api compat error * moving headinglevel ids enum to only the places where it is necessary * reverting baseline files * removing disclaimer * removing switches Co-authored-by: Ryland <41491307+ryalanms@users.noreply.github.com> Co-authored-by: Felipe da Conceicao Guimaraes <felipeda@microsoft.com> Co-authored-by: ThomasGoulet73 <51839772+ThomasGoulet73@users.noreply.github.com> Co-authored-by: Sam Bent <sambent@microsoft.com>
- Loading branch information
1 parent
85d9507
commit 27a2ce3
Showing
22 changed files
with
545 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
69 changes: 69 additions & 0 deletions
69
...osoft.DotNet.Wpf/src/PresentationCore/System/Windows/Automation/AutomationHeadingLevel.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,69 @@ | ||
// Licensed to the .NET Foundation under one or more agreements. | ||
// The .NET Foundation licenses this file to you under the MIT license. | ||
// See the LICENSE file in the project root for more information. | ||
|
||
// | ||
// | ||
// | ||
// Description: Enumeration for possible values of AutomationProperties.HeadingLevel | ||
// | ||
|
||
namespace System.Windows.Automation | ||
{ | ||
/// <summary> | ||
/// Describes the heading level of a control | ||
/// </summary> | ||
public enum AutomationHeadingLevel | ||
{ | ||
/// <summary> | ||
/// The element does not have a heading level | ||
/// </summary> | ||
None = 0, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 1 | ||
/// </summary> | ||
Level1, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 2 | ||
/// </summary> | ||
Level2, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 3 | ||
/// </summary> | ||
Level3, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 4 | ||
/// </summary> | ||
Level4, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 5 | ||
/// </summary> | ||
Level5, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 6 | ||
/// </summary> | ||
Level6, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 7 | ||
/// </summary> | ||
Level7, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 8 | ||
/// </summary> | ||
Level8, | ||
|
||
/// <summary> | ||
/// The element has a heading level of 9 | ||
/// </summary> | ||
Level9, | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.