Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(297)

Unified Diff: ui/accessibility/platform/ax_platform_node_win.cc

Issue 2781613003: Added a class acting as a fake caret for accessibility. (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/accessibility/platform/ax_platform_node_win.cc
diff --git a/ui/accessibility/platform/ax_platform_node_win.cc b/ui/accessibility/platform/ax_platform_node_win.cc
index d811182f2f17fceaac6f803e3c159df170953c28..8d36b590b1e95df9b3de4691c2c07234ccce1c86 100644
--- a/ui/accessibility/platform/ax_platform_node_win.cc
+++ b/ui/accessibility/platform/ax_platform_node_win.cc
@@ -181,6 +181,12 @@ void AXPlatformNodeWin::NotifyAccessibilityEvent(ui::AXEvent event_type) {
::NotifyWinEvent(native_event, hwnd, OBJID_CLIENT, -unique_id_);
+ if (event_type == ui::AX_EVENT_TEXT_SELECTION_CHANGED) {
+ // We also need to fire an older MSAA event used by some assistive software.
dougt 2017/03/28 15:23:44 Nit: comment is odd here since we're not dispatchi
+ ::NotifyWinEvent(EVENT_OBJECT_LOCATIONCHANGE, hwnd, OBJID_CARET,
+ -unique_id_);
+ }
+
// Keep track of objects that are a target of an alert event.
if (event_type == ui::AX_EVENT_ALERT)
AddAlertTarget();

Powered by Google App Engine
This is Rietveld 408576698