summaryrefslogtreecommitdiffstats
path: root/chrome/browser/background_mode_manager.cc
diff options
context:
space:
mode:
authortfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-30 05:39:14 +0000
committertfarina@chromium.org <tfarina@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-09-30 05:39:14 +0000
commit73c0dce6d99c48fd731da072e978080e4fcb9143 (patch)
tree0f313ee445eb60aa3ed59216d12aab9df3e4ed7b /chrome/browser/background_mode_manager.cc
parenta9ecca3aabf9ea092a1ce086a3ea54870fedcfa8 (diff)
downloadchromium_src-73c0dce6d99c48fd731da072e978080e4fcb9143.zip
chromium_src-73c0dce6d99c48fd731da072e978080e4fcb9143.tar.gz
chromium_src-73c0dce6d99c48fd731da072e978080e4fcb9143.tar.bz2
Change the menu item 'Options' to 'Settings' on the status icon.
Also match the order of the menu items with the wrench menu. BUG=56152 TEST=out/Debug/chrome --enable-background-mode --keep-alive-for-test --enable-tabbed-options Go to the chromium status icon, you should see a 'Settings' menu item. Also without the switch you should still see the 'Options/Preferences' menu item. Review URL: http://codereview.chromium.org/3531003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@61030 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/background_mode_manager.cc')
-rw-r--r--chrome/browser/background_mode_manager.cc23
1 files changed, 14 insertions, 9 deletions
diff --git a/chrome/browser/background_mode_manager.cc b/chrome/browser/background_mode_manager.cc
index b0110a1..ba952cb 100644
--- a/chrome/browser/background_mode_manager.cc
+++ b/chrome/browser/background_mode_manager.cc
@@ -400,20 +400,25 @@ void BackgroundModeManager::CreateStatusTrayIcon() {
// Create a context menu item for Chrome.
menus::SimpleMenuModel* menu = new menus::SimpleMenuModel(this);
- menu->AddItem(IDC_ABOUT, l10n_util::GetStringFUTF16(IDS_ABOUT,
- l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)));
-
+ if (CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableTabbedOptions)) {
+ menu->AddItemWithStringId(IDC_OPTIONS, IDS_SETTINGS);
+ } else {
#if defined(TOOLKIT_GTK)
- string16 preferences = gtk_util::GetStockPreferencesMenuLabel();
- if (preferences.empty())
- menu->AddItemWithStringId(IDC_OPTIONS, IDS_OPTIONS);
- else
- menu->AddItem(IDC_OPTIONS, preferences);
+ string16 preferences = gtk_util::GetStockPreferencesMenuLabel();
+ if (preferences.empty())
+ menu->AddItemWithStringId(IDC_OPTIONS, IDS_OPTIONS);
+ else
+ menu->AddItem(IDC_OPTIONS, preferences);
#else
- menu->AddItemWithStringId(IDC_OPTIONS, IDS_OPTIONS);
+ menu->AddItemWithStringId(IDC_OPTIONS, IDS_OPTIONS);
#endif
+ }
+ menu->AddItem(IDC_ABOUT, l10n_util::GetStringFUTF16(IDS_ABOUT,
+ l10n_util::GetStringUTF16(IDS_PRODUCT_NAME)));
menu->AddSeparator();
menu->AddItemWithStringId(IDC_EXIT, IDS_EXIT);
+
status_icon_->SetContextMenu(menu);
}