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

Unified Diff: ui/views/accessibility/ax_view_obj_wrapper.cc

Issue 1644863003: Prune invisible views from the desktop automation tree (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | ui/views/accessibility/ax_widget_obj_wrapper.cc » ('j') | ui/views/view.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/views/accessibility/ax_view_obj_wrapper.cc
diff --git a/ui/views/accessibility/ax_view_obj_wrapper.cc b/ui/views/accessibility/ax_view_obj_wrapper.cc
index 4363d19dc71c5de9a9bcbb0239d27afdf139038d..d4a2c4325d04f9ee87296df3aef8bcdee2394125 100644
--- a/ui/views/accessibility/ax_view_obj_wrapper.cc
+++ b/ui/views/accessibility/ax_view_obj_wrapper.cc
@@ -36,6 +36,9 @@ void AXViewObjWrapper::GetChildren(
std::vector<AXAuraObjWrapper*>* out_children) {
// TODO(dtseng): Need to handle |Widget| child of |View|.
for (int i = 0; i < view_->child_count(); ++i) {
+ if (!view_->child_at(i)->visible())
+ continue;
+
AXAuraObjWrapper* child =
AXAuraObjCache::GetInstance()->GetOrCreate(view_->child_at(i));
out_children->push_back(child);
« no previous file with comments | « no previous file | ui/views/accessibility/ax_widget_obj_wrapper.cc » ('j') | ui/views/view.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698