| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "ui/views/accessibility/ax_window_obj_wrapper.h" | 5 #include "ui/views/accessibility/ax_window_obj_wrapper.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/strings/utf_string_conversions.h" | 9 #include "base/strings/utf_string_conversions.h" |
| 10 #include "ui/accessibility/ax_node_data.h" | 10 #include "ui/accessibility/ax_node_data.h" |
| (...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 if (widget) | 69 if (widget) |
| 70 AXAuraObjCache::GetInstance()->Remove(widget); | 70 AXAuraObjCache::GetInstance()->Remove(widget); |
| 71 } | 71 } |
| 72 | 72 |
| 73 void AXWindowObjWrapper::OnWindowHierarchyChanged( | 73 void AXWindowObjWrapper::OnWindowHierarchyChanged( |
| 74 const HierarchyChangeParams& params) { | 74 const HierarchyChangeParams& params) { |
| 75 if (params.phase == WindowObserver::HierarchyChangeParams::HIERARCHY_CHANGED) | 75 if (params.phase == WindowObserver::HierarchyChangeParams::HIERARCHY_CHANGED) |
| 76 AXAuraObjCache::GetInstance()->Remove(params.target, params.old_parent); | 76 AXAuraObjCache::GetInstance()->Remove(params.target, params.old_parent); |
| 77 } | 77 } |
| 78 | 78 |
| 79 void AXWindowObjWrapper::OnWindowBoundsChanged(aura::Window* window, |
| 80 const gfx::Rect& old_bounds, |
| 81 const gfx::Rect& new_bounds) { |
| 82 Widget* widget = Widget::GetWidgetForNativeView(window); |
| 83 if (widget) { |
| 84 widget->GetRootView()->NotifyAccessibilityEvent( |
| 85 ui::AX_EVENT_LOCATION_CHANGED, true); |
| 86 } |
| 87 } |
| 88 |
| 79 } // namespace views | 89 } // namespace views |
| OLD | NEW |