This repository was archived by the owner on Feb 25, 2025. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 6k
Announce alerts through SemanticsService on Windows #36966
Merged
yaakovschectman
merged 21 commits into
flutter:main
from
yaakovschectman:announce_alert
Oct 27, 2022
Merged
Changes from 1 commit
Commits
Show all changes
21 commits
Select commit
Hold shift + click to select a range
9def664
Pickup announcement messages
yaakovschectman cc0913c
Create files necessary for alert node
yaakovschectman 0ead656
Create skeleton of classes used
yaakovschectman 03acbea
Hold my progress
yaakovschectman 5aa0828
Announcements get read :)
yaakovschectman 1d3b910
Reads announcements
yaakovschectman 1873b2d
Unit test alert node
yaakovschectman f0a3810
Linux tests
yaakovschectman 8ab628a
PR
yaakovschectman 62e4ecc
Update shell/platform/windows/accessibility_root_node.h
yaakovschectman dc219b2
Add comment
yaakovschectman 0c43076
Expect call to wrapper
yaakovschectman c0d5a17
Unit test announcement message
yaakovschectman 885f4dc
Format
yaakovschectman 1ccb847
Constants in fixture
yaakovschectman da7a773
PR
yaakovschectman 957f9f5
Update shell/platform/windows/accessibility_root_node.h
yaakovschectman 3876e99
Update shell/platform/windows/accessibility_alert.h
yaakovschectman de9da98
Release a11y node if non null
yaakovschectman 9317a88
Reorder methods
yaakovschectman 2dfd8ec
Remove TODO
yaakovschectman File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Reorder methods
- Loading branch information
commit 9317a8842818c1612c515b010c1942493c5982ff
There are no files selected for viewing
This file contains hidden or 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 |
|---|---|---|
|
|
@@ -24,23 +24,6 @@ IFACEMETHODIMP AccessibilityAlert::accDoDefaultAction(VARIANT var_id) { | |
| return E_FAIL; | ||
| } | ||
|
|
||
| // Retrieves the specified object's current screen location. | ||
| IFACEMETHODIMP AccessibilityAlert::accLocation(LONG* physical_pixel_left, | ||
| LONG* physical_pixel_top, | ||
| LONG* width, | ||
| LONG* height, | ||
| VARIANT var_id) { | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // Traverses to another UI element and retrieves the object. | ||
| IFACEMETHODIMP AccessibilityAlert::accNavigate(LONG nav_dir, | ||
| VARIANT start, | ||
| VARIANT* end) { | ||
| end->vt = VT_EMPTY; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // Retrieves an IDispatch interface pointer for the specified child. | ||
| IFACEMETHODIMP AccessibilityAlert::get_accChild(VARIANT var_child, | ||
| IDispatch** disp_child) { | ||
|
|
@@ -59,33 +42,13 @@ IFACEMETHODIMP AccessibilityAlert::get_accChildCount(LONG* child_count) { | |
| return S_OK; | ||
| } | ||
|
|
||
| // Retrieves a string that describes the object's default action. | ||
| IFACEMETHODIMP AccessibilityAlert::get_accDefaultAction(VARIANT var_id, | ||
| BSTR* default_action) { | ||
| *default_action = nullptr; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // Retrieves the tooltip description. | ||
| IFACEMETHODIMP AccessibilityAlert::get_accDescription(VARIANT var_id, | ||
| BSTR* desc) { | ||
| *desc = SysAllocString(text_.c_str()); | ||
| return S_OK; | ||
| } | ||
|
|
||
| // Retrieves the object that has the keyboard focus. | ||
| IFACEMETHODIMP AccessibilityAlert::get_accFocus(VARIANT* focus_child) { | ||
| focus_child->vt = VT_EMPTY; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // Retrieves the specified object's shortcut. | ||
| IFACEMETHODIMP AccessibilityAlert::get_accKeyboardShortcut(VARIANT var_id, | ||
| BSTR* access_key) { | ||
| *access_key = nullptr; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // Retrieves the name of the specified object. | ||
| IFACEMETHODIMP AccessibilityAlert::get_accName(VARIANT var_id, BSTR* name) { | ||
| *name = SysAllocString(text_.c_str()); | ||
|
|
@@ -129,11 +92,6 @@ IFACEMETHODIMP AccessibilityAlert::get_accValue(VARIANT var_id, BSTR* value) { | |
| return S_OK; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::put_accValue(VARIANT var_id, | ||
| BSTR new_value) { | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // IAccessible methods not implemented. | ||
loic-sharma marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| IFACEMETHODIMP AccessibilityAlert::get_accSelection(VARIANT* selected) { | ||
| selected->vt = VT_EMPTY; | ||
|
|
@@ -144,6 +102,16 @@ IFACEMETHODIMP AccessibilityAlert::accSelect(LONG flags_sel, VARIANT var_id) { | |
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::put_accValue(VARIANT var_id, | ||
| BSTR new_value) { | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::get_accFocus(VARIANT* focus_child) { | ||
| focus_child->vt = VT_EMPTY; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::get_accHelpTopic(BSTR* help_file, | ||
| VARIANT var_id, | ||
| LONG* topic_id) { | ||
|
|
@@ -155,10 +123,38 @@ IFACEMETHODIMP AccessibilityAlert::get_accHelpTopic(BSTR* help_file, | |
| } | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::put_accName(VARIANT var_id, BSTR put_name) { | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe add a comment indicates the below methods are not part of IAccessible. Currently this is in the |
||
| IFACEMETHODIMP AccessibilityAlert::get_accKeyboardShortcut(VARIANT var_id, | ||
| BSTR* access_key) { | ||
| *access_key = nullptr; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::accLocation(LONG* physical_pixel_left, | ||
| LONG* physical_pixel_top, | ||
| LONG* width, | ||
| LONG* height, | ||
| VARIANT var_id) { | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::accNavigate(LONG nav_dir, | ||
| VARIANT start, | ||
| VARIANT* end) { | ||
| end->vt = VT_EMPTY; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| IFACEMETHODIMP AccessibilityAlert::get_accDefaultAction(VARIANT var_id, | ||
| BSTR* default_action) { | ||
| *default_action = nullptr; | ||
| return E_NOTIMPL; | ||
| } | ||
|
|
||
| // End of IAccessible methods. | ||
|
|
||
| void AccessibilityAlert::SetText(const std::wstring& text) { | ||
|
|
||
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.