Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(259)

Side by Side Diff: views/controls/menu/menu_item_view.h

Issue 7044016: Replace ButtonDropDown menu implementation (Menu2) with MenuItemView. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: One last little style fix. Created 9 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « views/controls/menu/menu_delegate.cc ('k') | views/controls/menu/menu_item_view.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 VIEWS_CONTROLS_MENU_MENU_ITEM_VIEW_H_ 5 #ifndef VIEWS_CONTROLS_MENU_MENU_ITEM_VIEW_H_
6 #define VIEWS_CONTROLS_MENU_MENU_ITEM_VIEW_H_ 6 #define VIEWS_CONTROLS_MENU_MENU_ITEM_VIEW_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 72
73 // The menu item view's class name. 73 // The menu item view's class name.
74 static const char kViewClassName[]; 74 static const char kViewClassName[];
75 75
76 // ID used to identify menu items. 76 // ID used to identify menu items.
77 static const int kMenuItemViewID; 77 static const int kMenuItemViewID;
78 78
79 // ID used to identify empty menu items. 79 // ID used to identify empty menu items.
80 static const int kEmptyMenuItemViewID; 80 static const int kEmptyMenuItemViewID;
81 81
82 // Different types of menu items. 82 // Different types of menu items. EMPTY is a special type for empty
83 // menus that is only used internally.
83 enum Type { 84 enum Type {
84 NORMAL, 85 NORMAL,
85 SUBMENU, 86 SUBMENU,
86 CHECKBOX, 87 CHECKBOX,
87 RADIO, 88 RADIO,
88 SEPARATOR 89 SEPARATOR,
90 EMPTY
89 }; 91 };
90 92
91 // Where the menu should be anchored to. 93 // Where the menu should be anchored to.
92 enum AnchorPosition { 94 enum AnchorPosition {
93 TOPLEFT, 95 TOPLEFT,
94 TOPRIGHT 96 TOPRIGHT
95 }; 97 };
96 98
97 // Constructor for use with the top level menu item. This menu is never 99 // Constructor for use with the top level menu item. This menu is never
98 // shown to the user, rather its use as the parent for all menu items. 100 // shown to the user, rather its use as the parent for all menu items.
(...skipping 359 matching lines...) Expand 10 before | Expand all | Expand 10 after
458 // Margins in pixels. 460 // Margins in pixels.
459 int top_margin_; 461 int top_margin_;
460 int bottom_margin_; 462 int bottom_margin_;
461 463
462 DISALLOW_COPY_AND_ASSIGN(MenuItemView); 464 DISALLOW_COPY_AND_ASSIGN(MenuItemView);
463 }; 465 };
464 466
465 } // namespace views 467 } // namespace views
466 468
467 #endif // VIEWS_CONTROLS_MENU_MENU_ITEM_VIEW_H_ 469 #endif // VIEWS_CONTROLS_MENU_MENU_ITEM_VIEW_H_
OLDNEW
« no previous file with comments | « views/controls/menu/menu_delegate.cc ('k') | views/controls/menu/menu_item_view.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698