Chromium Code Reviews| 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_RUNNER_H_ | 5 #ifndef UI_VIEWS_CONTROLS_MENU_MENU_RUNNER_H_ |
| 6 #define UI_VIEWS_CONTROLS_MENU_MENU_RUNNER_H_ | 6 #define UI_VIEWS_CONTROLS_MENU_MENU_RUNNER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/compiler_specific.h" | 9 #include "base/compiler_specific.h" |
| 10 #include "ui/views/controls/menu/menu_item_view.h" | 10 #include "ui/views/controls/menu/menu_item_view.h" |
| (...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 45 HAS_MNEMONICS = 1 << 0, | 45 HAS_MNEMONICS = 1 << 0, |
| 46 | 46 |
| 47 // The menu is a nested context menu. For example, click a folder on the | 47 // The menu is a nested context menu. For example, click a folder on the |
| 48 // bookmark bar, then right click an entry to get its context menu. | 48 // bookmark bar, then right click an entry to get its context menu. |
| 49 IS_NESTED = 1 << 1, | 49 IS_NESTED = 1 << 1, |
| 50 | 50 |
| 51 // Used for showing a menu during a drop operation. This does NOT block the | 51 // Used for showing a menu during a drop operation. This does NOT block the |
| 52 // caller, instead the delegate is notified when the menu closes via the | 52 // caller, instead the delegate is notified when the menu closes via the |
| 53 // DropMenuClosed method. | 53 // DropMenuClosed method. |
| 54 FOR_DROP = 1 << 2, | 54 FOR_DROP = 1 << 2, |
| 55 | |
| 56 // The menu is a context menu (not necessarily nested), For example right | |
|
sky
2012/08/20 21:13:48
nit: For -> for, or ',' -> '.'
Harry McCleave
2012/08/21 01:30:18
Done.
| |
| 57 // click on a link on a website in the browser. | |
| 58 CONTEXT_MENU = 1 << 3, | |
| 55 }; | 59 }; |
| 56 | 60 |
| 57 enum RunResult { | 61 enum RunResult { |
| 58 // Indicates RunMenuAt is returning because the MenuRunner was deleted. | 62 // Indicates RunMenuAt is returning because the MenuRunner was deleted. |
| 59 MENU_DELETED, | 63 MENU_DELETED, |
| 60 | 64 |
| 61 // Indicates RunMenuAt returned and MenuRunner was not deleted. | 65 // Indicates RunMenuAt returned and MenuRunner was not deleted. |
| 62 NORMAL_EXIT | 66 NORMAL_EXIT |
| 63 }; | 67 }; |
| 64 | 68 |
| (...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 114 | 118 |
| 115 protected: | 119 protected: |
| 116 DisplayChangeListener() {} | 120 DisplayChangeListener() {} |
| 117 }; | 121 }; |
| 118 | 122 |
| 119 } | 123 } |
| 120 | 124 |
| 121 } // namespace views | 125 } // namespace views |
| 122 | 126 |
| 123 #endif // UI_VIEWS_CONTROLS_MENU_MENU_RUNNER_H_ | 127 #endif // UI_VIEWS_CONTROLS_MENU_MENU_RUNNER_H_ |
| OLD | NEW |