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_CONTROLS_MENU_MENU_CONTROLLER_H_ | 5 #ifndef UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ |
6 #define UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ | 6 #define UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ |
7 | 7 |
8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
9 | 9 |
10 #include <list> | 10 #include <list> |
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
157 void OnDragWillStart(); | 157 void OnDragWillStart(); |
158 | 158 |
159 // Called by the Widget when the drag has completed. |should_close| | 159 // Called by the Widget when the drag has completed. |should_close| |
160 // corresponds to whether or not the menu should close. | 160 // corresponds to whether or not the menu should close. |
161 void OnDragComplete(bool should_close); | 161 void OnDragComplete(bool should_close); |
162 | 162 |
163 // Update the submenu's selection based on the current mouse location | 163 // Update the submenu's selection based on the current mouse location |
164 void UpdateSubmenuSelection(SubmenuView* source); | 164 void UpdateSubmenuSelection(SubmenuView* source); |
165 | 165 |
166 // WidgetObserver overrides: | 166 // WidgetObserver overrides: |
167 virtual void OnWidgetDestroying(Widget* widget) OVERRIDE; | 167 virtual void OnWidgetDestroying(Widget* widget) override; |
168 | 168 |
169 // Only used for testing. | 169 // Only used for testing. |
170 bool IsCancelAllTimerRunningForTest(); | 170 bool IsCancelAllTimerRunningForTest(); |
171 | 171 |
172 // Only used for testing. | 172 // Only used for testing. |
173 static void TurnOffMenuSelectionHoldForTest(); | 173 static void TurnOffMenuSelectionHoldForTest(); |
174 | 174 |
175 private: | 175 private: |
176 friend class internal::MenuEventDispatcher; | 176 friend class internal::MenuEventDispatcher; |
177 friend class internal::MenuMessagePumpDispatcher; | 177 friend class internal::MenuMessagePumpDispatcher; |
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
632 bool item_selected_by_touch_; | 632 bool item_selected_by_touch_; |
633 | 633 |
634 scoped_ptr<MenuMessageLoop> message_loop_; | 634 scoped_ptr<MenuMessageLoop> message_loop_; |
635 | 635 |
636 DISALLOW_COPY_AND_ASSIGN(MenuController); | 636 DISALLOW_COPY_AND_ASSIGN(MenuController); |
637 }; | 637 }; |
638 | 638 |
639 } // namespace views | 639 } // namespace views |
640 | 640 |
641 #endif // UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ | 641 #endif // UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ |
OLD | NEW |