OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef UI_VIEWS_WIDGET_ROOT_VIEW_H_ | 5 #ifndef UI_VIEWS_WIDGET_ROOT_VIEW_H_ |
6 #define UI_VIEWS_WIDGET_ROOT_VIEW_H_ | 6 #define UI_VIEWS_WIDGET_ROOT_VIEW_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/memory/ref_counted.h" | 10 #include "base/memory/ref_counted.h" |
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
80 | 80 |
81 // Public API for broadcasting theme change notifications to this View | 81 // Public API for broadcasting theme change notifications to this View |
82 // hierarchy. | 82 // hierarchy. |
83 void ThemeChanged(); | 83 void ThemeChanged(); |
84 | 84 |
85 // Public API for broadcasting locale change notifications to this View | 85 // Public API for broadcasting locale change notifications to this View |
86 // hierarchy. | 86 // hierarchy. |
87 void LocaleChanged(); | 87 void LocaleChanged(); |
88 | 88 |
89 // Overridden from FocusTraversable: | 89 // Overridden from FocusTraversable: |
90 virtual FocusSearch* GetFocusSearch() OVERRIDE; | 90 virtual FocusSearch* GetFocusSearch() override; |
91 virtual FocusTraversable* GetFocusTraversableParent() OVERRIDE; | 91 virtual FocusTraversable* GetFocusTraversableParent() override; |
92 virtual View* GetFocusTraversableParentView() OVERRIDE; | 92 virtual View* GetFocusTraversableParentView() override; |
93 | 93 |
94 // Overridden from ui::EventProcessor: | 94 // Overridden from ui::EventProcessor: |
95 virtual ui::EventTarget* GetRootTarget() OVERRIDE; | 95 virtual ui::EventTarget* GetRootTarget() override; |
96 virtual void OnEventProcessingStarted(ui::Event* event) OVERRIDE; | 96 virtual void OnEventProcessingStarted(ui::Event* event) override; |
97 virtual void OnEventProcessingFinished(ui::Event* event) OVERRIDE; | 97 virtual void OnEventProcessingFinished(ui::Event* event) override; |
98 | 98 |
99 // Overridden from View: | 99 // Overridden from View: |
100 virtual const Widget* GetWidget() const OVERRIDE; | 100 virtual const Widget* GetWidget() const override; |
101 virtual Widget* GetWidget() OVERRIDE; | 101 virtual Widget* GetWidget() override; |
102 virtual bool IsDrawn() const OVERRIDE; | 102 virtual bool IsDrawn() const override; |
103 virtual void Layout() OVERRIDE; | 103 virtual void Layout() override; |
104 virtual const char* GetClassName() const OVERRIDE; | 104 virtual const char* GetClassName() const override; |
105 virtual void SchedulePaintInRect(const gfx::Rect& rect) OVERRIDE; | 105 virtual void SchedulePaintInRect(const gfx::Rect& rect) override; |
106 virtual bool OnMousePressed(const ui::MouseEvent& event) OVERRIDE; | 106 virtual bool OnMousePressed(const ui::MouseEvent& event) override; |
107 virtual bool OnMouseDragged(const ui::MouseEvent& event) OVERRIDE; | 107 virtual bool OnMouseDragged(const ui::MouseEvent& event) override; |
108 virtual void OnMouseReleased(const ui::MouseEvent& event) OVERRIDE; | 108 virtual void OnMouseReleased(const ui::MouseEvent& event) override; |
109 virtual void OnMouseCaptureLost() OVERRIDE; | 109 virtual void OnMouseCaptureLost() override; |
110 virtual void OnMouseMoved(const ui::MouseEvent& event) OVERRIDE; | 110 virtual void OnMouseMoved(const ui::MouseEvent& event) override; |
111 virtual void OnMouseExited(const ui::MouseEvent& event) OVERRIDE; | 111 virtual void OnMouseExited(const ui::MouseEvent& event) override; |
112 virtual bool OnMouseWheel(const ui::MouseWheelEvent& event) OVERRIDE; | 112 virtual bool OnMouseWheel(const ui::MouseWheelEvent& event) override; |
113 virtual void SetMouseHandler(View* new_mouse_handler) OVERRIDE; | 113 virtual void SetMouseHandler(View* new_mouse_handler) override; |
114 virtual void GetAccessibleState(ui::AXViewState* state) OVERRIDE; | 114 virtual void GetAccessibleState(ui::AXViewState* state) override; |
115 virtual void UpdateParentLayer() OVERRIDE; | 115 virtual void UpdateParentLayer() override; |
116 | 116 |
117 protected: | 117 protected: |
118 // Overridden from View: | 118 // Overridden from View: |
119 virtual void ViewHierarchyChanged( | 119 virtual void ViewHierarchyChanged( |
120 const ViewHierarchyChangedDetails& details) OVERRIDE; | 120 const ViewHierarchyChangedDetails& details) override; |
121 virtual void VisibilityChanged(View* starting_from, bool is_visible) OVERRIDE; | 121 virtual void VisibilityChanged(View* starting_from, bool is_visible) override; |
122 virtual void OnPaint(gfx::Canvas* canvas) OVERRIDE; | 122 virtual void OnPaint(gfx::Canvas* canvas) override; |
123 virtual gfx::Vector2d CalculateOffsetToAncestorWithLayer( | 123 virtual gfx::Vector2d CalculateOffsetToAncestorWithLayer( |
124 ui::Layer** layer_parent) OVERRIDE; | 124 ui::Layer** layer_parent) override; |
125 virtual View::DragInfo* GetDragInfo() OVERRIDE; | 125 virtual View::DragInfo* GetDragInfo() override; |
126 | 126 |
127 private: | 127 private: |
128 friend class ::views::RootViewTargeter; | 128 friend class ::views::RootViewTargeter; |
129 friend class ::views::View; | 129 friend class ::views::View; |
130 friend class ::views::Widget; | 130 friend class ::views::Widget; |
131 friend class ::views::test::ViewTargeterTest; | 131 friend class ::views::test::ViewTargeterTest; |
132 friend class ::views::test::WidgetTest; | 132 friend class ::views::test::WidgetTest; |
133 | 133 |
134 // Input --------------------------------------------------------------------- | 134 // Input --------------------------------------------------------------------- |
135 | 135 |
(...skipping 11 matching lines...) Expand all Loading... |
147 | 147 |
148 // |view| is the view receiving |event|. This function sends the event to all | 148 // |view| is the view receiving |event|. This function sends the event to all |
149 // the Views up the hierarchy that has |notify_enter_exit_on_child_| flag | 149 // the Views up the hierarchy that has |notify_enter_exit_on_child_| flag |
150 // turned on, but does not contain |sibling|. | 150 // turned on, but does not contain |sibling|. |
151 void NotifyEnterExitOfDescendant(const ui::MouseEvent& event, | 151 void NotifyEnterExitOfDescendant(const ui::MouseEvent& event, |
152 ui::EventType type, | 152 ui::EventType type, |
153 View* view, | 153 View* view, |
154 View* sibling); | 154 View* sibling); |
155 | 155 |
156 // Overridden from ui::EventDispatcherDelegate: | 156 // Overridden from ui::EventDispatcherDelegate: |
157 virtual bool CanDispatchToTarget(ui::EventTarget* target) OVERRIDE; | 157 virtual bool CanDispatchToTarget(ui::EventTarget* target) override; |
158 virtual ui::EventDispatchDetails PreDispatchEvent(ui::EventTarget* target, | 158 virtual ui::EventDispatchDetails PreDispatchEvent(ui::EventTarget* target, |
159 ui::Event* event) OVERRIDE; | 159 ui::Event* event) override; |
160 virtual ui::EventDispatchDetails PostDispatchEvent( | 160 virtual ui::EventDispatchDetails PostDispatchEvent( |
161 ui::EventTarget* target, const ui::Event& event) OVERRIDE; | 161 ui::EventTarget* target, const ui::Event& event) override; |
162 | 162 |
163 ////////////////////////////////////////////////////////////////////////////// | 163 ////////////////////////////////////////////////////////////////////////////// |
164 // Tree operations ----------------------------------------------------------- | 164 // Tree operations ----------------------------------------------------------- |
165 | 165 |
166 // The host Widget | 166 // The host Widget |
167 Widget* widget_; | 167 Widget* widget_; |
168 | 168 |
169 // Input --------------------------------------------------------------------- | 169 // Input --------------------------------------------------------------------- |
170 | 170 |
171 // TODO(tdanderson): Consider moving the input-related members into | 171 // TODO(tdanderson): Consider moving the input-related members into |
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
227 // Tracks drag state for a view. | 227 // Tracks drag state for a view. |
228 View::DragInfo drag_info_; | 228 View::DragInfo drag_info_; |
229 | 229 |
230 DISALLOW_IMPLICIT_CONSTRUCTORS(RootView); | 230 DISALLOW_IMPLICIT_CONSTRUCTORS(RootView); |
231 }; | 231 }; |
232 | 232 |
233 } // namespace internal | 233 } // namespace internal |
234 } // namespace views | 234 } // namespace views |
235 | 235 |
236 #endif // UI_VIEWS_WIDGET_ROOT_VIEW_H_ | 236 #endif // UI_VIEWS_WIDGET_ROOT_VIEW_H_ |
OLD | NEW |