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

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

Issue 953723003: Guest mode doesn't show the Bookmarks item in Wrench Menu. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Browser test. Created 5 years, 10 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/profiles/profile_window_browsertest.cc ('k') | no next file » | 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 4f5087cdcb9523afe00ddea868fb7f07c1b0331b..ad3717f77a527f3784655e79eb19dc5dbfda5d5b 100644
--- a/chrome/browser/ui/toolbar/wrench_menu_model.cc
+++ b/chrome/browser/ui/toolbar/wrench_menu_model.cc
@@ -845,9 +845,11 @@ void WrenchMenuModel::Build() {
if (ShouldShowNewIncognitoWindowMenuItem())
AddItemWithStringId(IDC_NEW_INCOGNITO_WINDOW, IDS_NEW_INCOGNITO_WINDOW);
- bookmark_sub_menu_model_.reset(new BookmarkSubMenuModel(this, browser_));
- AddSubMenuWithStringId(IDC_BOOKMARKS_MENU, IDS_BOOKMARKS_MENU,
- bookmark_sub_menu_model_.get());
+ if (!browser_->profile()->IsGuestSession()) {
+ bookmark_sub_menu_model_.reset(new BookmarkSubMenuModel(this, browser_));
+ AddSubMenuWithStringId(IDC_BOOKMARKS_MENU, IDS_BOOKMARKS_MENU,
+ bookmark_sub_menu_model_.get());
+ }
if (!browser_->profile()->IsOffTheRecord()) {
recent_tabs_sub_menu_model_.reset(new RecentTabsSubMenuModel(provider_,
« no previous file with comments | « chrome/browser/profiles/profile_window_browsertest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698