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_delegate.h

Issue 7109037: views: Make MenuDelegate constructor virtual. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: 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 | « no previous file | views/controls/menu/menu_delegate.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_DELEGATE_H_ 5 #ifndef VIEWS_CONTROLS_MENU_MENU_DELEGATE_H_
6 #define VIEWS_CONTROLS_MENU_MENU_DELEGATE_H_ 6 #define VIEWS_CONTROLS_MENU_MENU_DELEGATE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <set> 9 #include <set>
10 #include <string> 10 #include <string>
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 // Indicates the drop should occur before the item. 44 // Indicates the drop should occur before the item.
45 DROP_BEFORE, 45 DROP_BEFORE,
46 46
47 // Indicates the drop should occur after the item. 47 // Indicates the drop should occur after the item.
48 DROP_AFTER, 48 DROP_AFTER,
49 49
50 // Indicates the drop should occur on the item. 50 // Indicates the drop should occur on the item.
51 DROP_ON 51 DROP_ON
52 }; 52 };
53 53
54 virtual ~MenuDelegate();
55
54 // Whether or not an item should be shown as checked. This is invoked for 56 // Whether or not an item should be shown as checked. This is invoked for
55 // radio buttons and check buttons. 57 // radio buttons and check buttons.
56 virtual bool IsItemChecked(int id) const; 58 virtual bool IsItemChecked(int id) const;
57 59
58 // The string shown for the menu item. This is only invoked when an item is 60 // The string shown for the menu item. This is only invoked when an item is
59 // added with an empty label. 61 // added with an empty label.
60 virtual std::wstring GetLabel(int id) const; 62 virtual std::wstring GetLabel(int id) const;
61 63
62 // The font for the menu item label. 64 // The font for the menu item label.
63 virtual const gfx::Font& GetLabelFont(int id) const; 65 virtual const gfx::Font& GetLabelFont(int id) const;
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 // Invoked prior to a menu being shown. 191 // Invoked prior to a menu being shown.
190 virtual void WillShowMenu(MenuItemView* menu); 192 virtual void WillShowMenu(MenuItemView* menu);
191 193
192 // Invoked prior to a menu being hidden. 194 // Invoked prior to a menu being hidden.
193 virtual void WillHideMenu(MenuItemView* menu); 195 virtual void WillHideMenu(MenuItemView* menu);
194 }; 196 };
195 197
196 } // namespace views 198 } // namespace views
197 199
198 #endif // VIEWS_CONTROLS_MENU_MENU_DELEGATE_H_ 200 #endif // VIEWS_CONTROLS_MENU_MENU_DELEGATE_H_
OLDNEW
« no previous file with comments | « no previous file | views/controls/menu/menu_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698