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

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

Issue 3026025: The Mac wrench menu zoom controls honor the global enabled state of the zoom commands. (Closed)
Patch Set: Removed unneeded disabling of percentage display. Created 10 years, 4 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/wrench_menu_model.h ('k') | no next file » | 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 #include "chrome/browser/wrench_menu_model.h" 5 #include "chrome/browser/wrench_menu_model.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "app/l10n_util.h" 10 #include "app/l10n_util.h"
(...skipping 378 matching lines...) Expand 10 before | Expand all | Expand 10 after
389 } 389 }
390 return l10n_util::GetStringFUTF16( 390 return l10n_util::GetStringFUTF16(
391 IDS_ABOUT, l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)); 391 IDS_ABOUT, l10n_util::GetStringUTF16(IDS_PRODUCT_NAME));
392 } 392 }
393 393
394 bool WrenchMenuModel::IsDynamicItem(int index) const { 394 bool WrenchMenuModel::IsDynamicItem(int index) const {
395 int command_id = GetCommandIdAt(index); 395 int command_id = GetCommandIdAt(index);
396 return command_id == IDC_SYNC_BOOKMARKS || 396 return command_id == IDC_SYNC_BOOKMARKS ||
397 command_id == IDC_ABOUT; 397 command_id == IDC_ABOUT;
398 } 398 }
399
400 bool WrenchMenuModel::IsCommandIdEnabled(int command_id) const {
401 if (delegate_)
402 return delegate_->IsCommandIdEnabled(command_id);
403 return true;
404 }
OLDNEW
« no previous file with comments | « chrome/browser/wrench_menu_model.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698