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

Unified Diff: content/renderer/accessibility/renderer_accessibility_complete.cc

Issue 637423003: Send AX event on nearest unignored ancestor of target. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@child_frame_no_ax_needed
Patch Set: Created 6 years, 2 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/accessibility/renderer_accessibility_complete.cc
diff --git a/content/renderer/accessibility/renderer_accessibility_complete.cc b/content/renderer/accessibility/renderer_accessibility_complete.cc
index f9807c053e886b9dec281f7621cdce681a33df3d..c637771db357669322958e154040736f6790e68b 100644
--- a/content/renderer/accessibility/renderer_accessibility_complete.cc
+++ b/content/renderer/accessibility/renderer_accessibility_complete.cc
@@ -209,6 +209,10 @@ void RendererAccessibilityComplete::SendPendingAccessibilityEvents() {
if (!obj.updateBackingStoreAndCheckValidity())
continue;
+ // If it's ignored, find the first ancestor that's not ignored.
+ while (!obj.isDetached() && obj.accessibilityIsIgnored())
+ obj = obj.parentObject();
+
// Make sure it's a descendant of our root node - exceptions include the
// scroll area that's the parent of the main document (we ignore it), and
// possibly nodes attached to a different document.
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698