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

Unified Diff: ash/shelf/shelf_view.cc

Issue 486193004: Ash: Fix browser icon menu model lifetime (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ash/shelf/shelf_view.h ('k') | ash/shelf/shelf_view_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/shelf/shelf_view.cc
diff --git a/ash/shelf/shelf_view.cc b/ash/shelf/shelf_view.cc
index 5e4f00255c028296401e34233c241e8af1e0803f..60267d9c189d69761fca75872ff6b0cdea7ac8d6 100644
--- a/ash/shelf/shelf_view.cc
+++ b/ash/shelf/shelf_view.cc
@@ -1719,8 +1719,10 @@ bool ShelfView::ShowListMenuForView(const ShelfItem& item,
// Make sure we have a menu and it has at least two items in addition to the
// application title and the 3 spacing separators.
- if (!list_menu_model_.get() || list_menu_model_->GetItemCount() <= 5)
+ if (!list_menu_model_.get() || list_menu_model_->GetItemCount() <= 5) {
+ list_menu_model_.reset();
return false;
+ }
ShowMenu(list_menu_model_.get(),
source,
« no previous file with comments | « ash/shelf/shelf_view.h ('k') | ash/shelf/shelf_view_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698