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

Unified Diff: chrome/browser/ui/toolbar/wrench_menu_model.cc

Issue 6250070: Added command line switches and UI (controlled via a build option) (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Address review concerns Created 9 years, 11 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/browser.cc ('k') | chrome/chrome_common.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/toolbar/wrench_menu_model.cc
diff --git a/chrome/browser/ui/toolbar/wrench_menu_model.cc b/chrome/browser/ui/toolbar/wrench_menu_model.cc
index 2028512925d8e5cf7101b77cc257a2d1c4a72562..3ac7b07f5c16bb84439c740f1c0cb7a7054750b5 100644
--- a/chrome/browser/ui/toolbar/wrench_menu_model.cc
+++ b/chrome/browser/ui/toolbar/wrench_menu_model.cc
@@ -30,6 +30,7 @@
#include "chrome/common/notification_source.h"
#include "chrome/common/notification_type.h"
#include "chrome/common/pref_names.h"
+#include "chrome/common/profiling.h"
#include "grit/chromium_strings.h"
#include "grit/generated_resources.h"
#include "grit/theme_resources.h"
@@ -184,6 +185,11 @@ void ToolsMenuModel::Build(Browser* browser) {
AddItemWithStringId(IDC_DEV_TOOLS, IDS_DEV_TOOLS);
AddItemWithStringId(IDC_DEV_TOOLS_CONSOLE, IDS_DEV_TOOLS_CONSOLE);
}
+
+#if defined(ENABLE_PROFILING) || !defined(NO_TCMALLOC)
+ AddSeparator();
+ AddCheckItemWithStringId(IDC_PROFILING_ENABLED, IDS_PROFILING_ENABLED);
+#endif
}
////////////////////////////////////////////////////////////////////////////////
@@ -279,6 +285,8 @@ void WrenchMenuModel::ExecuteCommand(int command_id) {
bool WrenchMenuModel::IsCommandIdChecked(int command_id) const {
if (command_id == IDC_SHOW_BOOKMARK_BAR) {
return browser_->profile()->GetPrefs()->GetBoolean(prefs::kShowBookmarkBar);
+ } else if (command_id == IDC_PROFILING_ENABLED) {
+ return Profiling::BeingProfiled();
}
return false;
« no previous file with comments | « chrome/browser/ui/browser.cc ('k') | chrome/chrome_common.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698