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
3 // found in the LICENSE file.
5 #ifndef UI_VIEWS_ACCESSIBILITY_AX_WIDGET_OBJ_WRAPPER_H_
6 #define UI_VIEWS_ACCESSIBILITY_AX_WIDGET_OBJ_WRAPPER_H_
8 #include "ui/views/accessibility/ax_aura_obj_wrapper.h"
9 #include "ui/views/widget/widget_observer.h"
10 #include "ui/views/widget/widget_removals_observer.h"
15 // Describes a |Widget| for use with other AX classes.
16 class AXWidgetObjWrapper
: public AXAuraObjWrapper
,
17 public WidgetObserver
,
18 public WidgetRemovalsObserver
{
20 explicit AXWidgetObjWrapper(Widget
* widget
);
21 ~AXWidgetObjWrapper() override
;
23 // AXAuraObjWrapper overrides.
24 AXAuraObjWrapper
* GetParent() override
;
25 void GetChildren(std::vector
<AXAuraObjWrapper
*>* out_children
) override
;
26 void Serialize(ui::AXNodeData
* out_node_data
) override
;
27 int32
GetID() override
;
29 // WidgetObserver overrides.
30 void OnWidgetDestroying(Widget
* widget
) override
;
32 // WidgetRemovalsObserver overrides.
33 void OnWillRemoveView(Widget
* widget
, View
* view
) override
;
38 DISALLOW_COPY_AND_ASSIGN(AXWidgetObjWrapper
);
43 #endif // UI_VIEWS_ACCESSIBILITY_AX_WIDGET_OBJ_WRAPPER_H_