Chromium Code Reviews| Index: ui/views/accessibility/ax_aura_obj_cache.cc |
| diff --git a/ui/views/accessibility/ax_aura_obj_cache.cc b/ui/views/accessibility/ax_aura_obj_cache.cc |
| index ad9df5c9fdd4d75a1b1e802c85352dd1de7f41f0..1f26711cd5890b33e04ccef088e497d5e5eda180 100644 |
| --- a/ui/views/accessibility/ax_aura_obj_cache.cc |
| +++ b/ui/views/accessibility/ax_aura_obj_cache.cc |
| @@ -124,6 +124,12 @@ void AXAuraObjCache::OnFocusedViewChanged() { |
| view->NotifyAccessibilityEvent(ui::AX_EVENT_FOCUS, true); |
| } |
| +void AXAuraObjCache::FireEvent(AXAuraObjWrapper* aura_obj, |
| + ui::AXEvent event_type) { |
| + if (delegate_) |
| + delegate_->OnEvent(aura_obj, event_type); |
| +} |
| + |
| AXAuraObjCache::AXAuraObjCache() |
| : current_id_(1), |
| focus_client_(nullptr), |
| @@ -181,6 +187,15 @@ void AXAuraObjCache::OnWindowDestroying(aura::Window* window) { |
| focus_client_ = nullptr; |
| } |
| +void AXAuraObjCache::OnWindowHierarchyChanged( |
|
David Tseng
2017/04/17 15:39:54
I don't know if this is what you really want. This
dmazzoni
2017/04/19 18:07:34
So on Chrome OS, there's only one root window for
David Tseng
2017/04/19 19:21:31
Please add a comment when we call root_window->Add
dmazzoni
2017/04/19 21:37:02
Done.
|
| + const HierarchyChangeParams& params) { |
| + aura::Window* window = params.target; |
| + if (window->parent()) { |
| + delegate_->OnEvent(GetOrCreate(window->parent()), |
| + ui::AX_EVENT_CHILDREN_CHANGED); |
| + } |
| +} |
| + |
| template <typename AuraViewWrapper, typename AuraView> |
| AXAuraObjWrapper* AXAuraObjCache::CreateInternal( |
| AuraView* aura_view, |