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 27 matching lines...) Expand all Loading... |
38 namespace internal { | 38 namespace internal { |
39 class MenuControllerDelegate; | 39 class MenuControllerDelegate; |
40 class MenuRunnerImpl; | 40 class MenuRunnerImpl; |
41 } | 41 } |
42 | 42 |
43 // MenuController ------------------------------------------------------------- | 43 // MenuController ------------------------------------------------------------- |
44 | 44 |
45 // MenuController is used internally by the various menu classes to manage | 45 // MenuController is used internally by the various menu classes to manage |
46 // showing, selecting and drag/drop for menus. All relevant events are | 46 // showing, selecting and drag/drop for menus. All relevant events are |
47 // forwarded to the MenuController from SubmenuView and MenuHost. | 47 // forwarded to the MenuController from SubmenuView and MenuHost. |
48 class VIEWS_EXPORT MenuController : public MessageLoop::Dispatcher, | 48 class VIEWS_EXPORT MenuController : public base::MessageLoop::Dispatcher, |
49 public WidgetObserver { | 49 public WidgetObserver { |
50 public: | 50 public: |
51 // Enumeration of how the menu should exit. | 51 // Enumeration of how the menu should exit. |
52 enum ExitType { | 52 enum ExitType { |
53 // Don't exit. | 53 // Don't exit. |
54 EXIT_NONE, | 54 EXIT_NONE, |
55 | 55 |
56 // All menus, including nested, should be exited. | 56 // All menus, including nested, should be exited. |
57 EXIT_ALL, | 57 EXIT_ALL, |
58 | 58 |
(...skipping 513 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
572 | 572 |
573 // Time when the menu is first shown. | 573 // Time when the menu is first shown. |
574 base::TimeTicks menu_start_time_; | 574 base::TimeTicks menu_start_time_; |
575 | 575 |
576 DISALLOW_COPY_AND_ASSIGN(MenuController); | 576 DISALLOW_COPY_AND_ASSIGN(MenuController); |
577 }; | 577 }; |
578 | 578 |
579 } // namespace views | 579 } // namespace views |
580 | 580 |
581 #endif // UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ | 581 #endif // UI_VIEWS_CONTROLS_MENU_MENU_CONTROLLER_H_ |
OLD | NEW |