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

Side by Side Diff: chrome/browser/wrench_menu_model.h

Issue 3143046: The "Update Chrome" menu item should appear in addition to the About menu. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: estade fixes -> final try Created 10 years, 3 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
« no previous file with comments | « chrome/browser/gtk/menu_gtk.cc ('k') | chrome/browser/wrench_menu_model.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) 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_WRENCH_MENU_MODEL_H_ 5 #ifndef CHROME_BROWSER_WRENCH_MENU_MODEL_H_
6 #define CHROME_BROWSER_WRENCH_MENU_MODEL_H_ 6 #define CHROME_BROWSER_WRENCH_MENU_MODEL_H_
7 #pragma once 7 #pragma once
8 8
9 #include "app/menus/accelerator.h" 9 #include "app/menus/accelerator.h"
10 #include "app/menus/button_menu_item_model.h" 10 #include "app/menus/button_menu_item_model.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 public: 76 public:
77 WrenchMenuModel(menus::AcceleratorProvider* provider, Browser* browser); 77 WrenchMenuModel(menus::AcceleratorProvider* provider, Browser* browser);
78 virtual ~WrenchMenuModel(); 78 virtual ~WrenchMenuModel();
79 79
80 // Overridden for both ButtonMenuItemModel::Delegate and SimpleMenuModel: 80 // Overridden for both ButtonMenuItemModel::Delegate and SimpleMenuModel:
81 virtual bool IsLabelForCommandIdDynamic(int command_id) const; 81 virtual bool IsLabelForCommandIdDynamic(int command_id) const;
82 virtual string16 GetLabelForCommandId(int command_id) const; 82 virtual string16 GetLabelForCommandId(int command_id) const;
83 virtual void ExecuteCommand(int command_id); 83 virtual void ExecuteCommand(int command_id);
84 virtual bool IsCommandIdChecked(int command_id) const; 84 virtual bool IsCommandIdChecked(int command_id) const;
85 virtual bool IsCommandIdEnabled(int command_id) const; 85 virtual bool IsCommandIdEnabled(int command_id) const;
86 virtual bool IsCommandIdVisible(int command_id) const;
86 virtual bool GetAcceleratorForCommandId( 87 virtual bool GetAcceleratorForCommandId(
87 int command_id, 88 int command_id,
88 menus::Accelerator* accelerator); 89 menus::Accelerator* accelerator);
89 90
90 // Overridden from TabStripModelObserver: 91 // Overridden from TabStripModelObserver:
91 virtual void TabSelectedAt(TabContents* old_contents, 92 virtual void TabSelectedAt(TabContents* old_contents,
92 TabContents* new_contents, 93 TabContents* new_contents,
93 int index, 94 int index,
94 bool user_gesture); 95 bool user_gesture);
95 virtual void TabReplacedAt(TabContents* old_contents, 96 virtual void TabReplacedAt(TabContents* old_contents,
(...skipping 20 matching lines...) Expand all
116 117
117 // Adds custom items to the menu. Deprecated in favor of a cross platform 118 // Adds custom items to the menu. Deprecated in favor of a cross platform
118 // model for button items. 119 // model for button items.
119 void CreateCutCopyPaste(); 120 void CreateCutCopyPaste();
120 void CreateZoomFullscreen(); 121 void CreateZoomFullscreen();
121 122
122 // Gets the current zoom information from the renderer. 123 // Gets the current zoom information from the renderer.
123 double GetZoom(bool* enable_increment, bool* enable_decrement); 124 double GetZoom(bool* enable_increment, bool* enable_decrement);
124 125
125 string16 GetSyncMenuLabel() const; 126 string16 GetSyncMenuLabel() const;
126 string16 GetAboutEntryMenuLabel() const;
127 127
128 // Models for the special menu items with buttons. 128 // Models for the special menu items with buttons.
129 scoped_ptr<menus::ButtonMenuItemModel> edit_menu_item_model_; 129 scoped_ptr<menus::ButtonMenuItemModel> edit_menu_item_model_;
130 scoped_ptr<menus::ButtonMenuItemModel> zoom_menu_item_model_; 130 scoped_ptr<menus::ButtonMenuItemModel> zoom_menu_item_model_;
131 131
132 // Label of the zoom label in the zoom menu item. 132 // Label of the zoom label in the zoom menu item.
133 string16 zoom_label_; 133 string16 zoom_label_;
134 134
135 // Tools menu. 135 // Tools menu.
136 scoped_ptr<ToolsMenuModel> tools_menu_model_; 136 scoped_ptr<ToolsMenuModel> tools_menu_model_;
137 137
138 menus::AcceleratorProvider* provider_; // weak 138 menus::AcceleratorProvider* provider_; // weak
139 139
140 Browser* browser_; // weak 140 Browser* browser_; // weak
141 TabStripModel* tabstrip_model_; // weak 141 TabStripModel* tabstrip_model_; // weak
142 142
143 NotificationRegistrar registrar_; 143 NotificationRegistrar registrar_;
144 144
145 DISALLOW_COPY_AND_ASSIGN(WrenchMenuModel); 145 DISALLOW_COPY_AND_ASSIGN(WrenchMenuModel);
146 }; 146 };
147 147
148 #endif // CHROME_BROWSER_WRENCH_MENU_MODEL_H_ 148 #endif // CHROME_BROWSER_WRENCH_MENU_MODEL_H_
OLDNEW
« no previous file with comments | « chrome/browser/gtk/menu_gtk.cc ('k') | chrome/browser/wrench_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698