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

Side by Side Diff: chrome/browser/ui/toolbar/back_forward_menu_model.h

Issue 5697005: Change SimpleMenuModel on OSX to support dynamic icons (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Update after merge Created 10 years 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 CHROME_BROWSER_UI_TOOLBAR_BACK_FORWARD_MENU_MODEL_H_ 5 #ifndef CHROME_BROWSER_UI_TOOLBAR_BACK_FORWARD_MENU_MODEL_H_
6 #define CHROME_BROWSER_UI_TOOLBAR_BACK_FORWARD_MENU_MODEL_H_ 6 #define CHROME_BROWSER_UI_TOOLBAR_BACK_FORWARD_MENU_MODEL_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 30 matching lines...) Expand all
41 // MenuModel implementation. 41 // MenuModel implementation.
42 virtual bool HasIcons() const; 42 virtual bool HasIcons() const;
43 // Returns how many items the menu should show, including history items, 43 // Returns how many items the menu should show, including history items,
44 // chapter-stops, separators and the Show Full History link. This function 44 // chapter-stops, separators and the Show Full History link. This function
45 // uses GetHistoryItemCount() and GetChapterStopCount() internally to figure 45 // uses GetHistoryItemCount() and GetChapterStopCount() internally to figure
46 // out the total number of items to show. 46 // out the total number of items to show.
47 virtual int GetItemCount() const; 47 virtual int GetItemCount() const;
48 virtual ItemType GetTypeAt(int index) const; 48 virtual ItemType GetTypeAt(int index) const;
49 virtual int GetCommandIdAt(int index) const; 49 virtual int GetCommandIdAt(int index) const;
50 virtual string16 GetLabelAt(int index) const; 50 virtual string16 GetLabelAt(int index) const;
51 virtual bool IsLabelDynamicAt(int index) const; 51 virtual bool IsItemDynamicAt(int index) const;
52 virtual bool GetAcceleratorAt(int index, 52 virtual bool GetAcceleratorAt(int index,
53 menus::Accelerator* accelerator) const; 53 menus::Accelerator* accelerator) const;
54 virtual bool IsItemCheckedAt(int index) const; 54 virtual bool IsItemCheckedAt(int index) const;
55 virtual int GetGroupIdAt(int index) const; 55 virtual int GetGroupIdAt(int index) const;
56 virtual bool GetIconAt(int index, SkBitmap* icon) const; 56 virtual bool GetIconAt(int index, SkBitmap* icon) const;
57 virtual menus::ButtonMenuItemModel* GetButtonMenuItemAt(int index) const; 57 virtual menus::ButtonMenuItemModel* GetButtonMenuItemAt(int index) const;
58 virtual bool IsEnabledAt(int index) const; 58 virtual bool IsEnabledAt(int index) const;
59 virtual MenuModel* GetSubmenuModelAt(int index) const; 59 virtual MenuModel* GetSubmenuModelAt(int index) const;
60 virtual void HighlightChangedTo(int index); 60 virtual void HighlightChangedTo(int index);
61 virtual void ActivatedAt(int index); 61 virtual void ActivatedAt(int index);
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 162
163 friend class BackFwdMenuModelTest; 163 friend class BackFwdMenuModelTest;
164 FRIEND_TEST_ALL_PREFIXES(BackFwdMenuModelTest, BasicCase); 164 FRIEND_TEST_ALL_PREFIXES(BackFwdMenuModelTest, BasicCase);
165 FRIEND_TEST_ALL_PREFIXES(BackFwdMenuModelTest, MaxItemsTest); 165 FRIEND_TEST_ALL_PREFIXES(BackFwdMenuModelTest, MaxItemsTest);
166 FRIEND_TEST_ALL_PREFIXES(BackFwdMenuModelTest, ChapterStops); 166 FRIEND_TEST_ALL_PREFIXES(BackFwdMenuModelTest, ChapterStops);
167 167
168 DISALLOW_COPY_AND_ASSIGN(BackForwardMenuModel); 168 DISALLOW_COPY_AND_ASSIGN(BackForwardMenuModel);
169 }; 169 };
170 170
171 #endif // CHROME_BROWSER_UI_TOOLBAR_BACK_FORWARD_MENU_MODEL_H_ 171 #endif // CHROME_BROWSER_UI_TOOLBAR_BACK_FORWARD_MENU_MODEL_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/menu_controller_unittest.mm ('k') | chrome/browser/ui/toolbar/back_forward_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698