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

Unified Diff: chrome/browser/tab_menu_model.h

Issue 1725006: Changes the tab menu to use pin and unpin instead of a check. The mac (Closed)
Patch Set: Merged with tip of tree and updated unit tests Created 10 years, 8 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/gtk/tabs/tab_gtk.cc ('k') | chrome/browser/tab_menu_model.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/tab_menu_model.h
diff --git a/chrome/browser/tab_menu_model.h b/chrome/browser/tab_menu_model.h
index c98731d38cae11ccb1f03bea24e4a69b04ceb381..dca49afd8f6a1038faa9b8dbaeaae6c3b80bc290 100644
--- a/chrome/browser/tab_menu_model.h
+++ b/chrome/browser/tab_menu_model.h
@@ -1,4 +1,4 @@
-// Copyright (c) 2009 The Chromium Authors. All rights reserved. Use of this
+// Copyright (c) 2010 The Chromium Authors. All rights reserved. Use of this
// source code is governed by a BSD-style license that can be found in the
// LICENSE file.
@@ -10,14 +10,16 @@
class Browser;
// A menu model that builds the contents of the tab context menu. This menu has
-// only one level (no submenus).
+// only one level (no submenus). TabMenuModel caches local state from the
+// tab (such as the pinned state). To make sure the menu reflects the real state
+// of the tab a new TabMenuModel should be created each time the menu is shown.
class TabMenuModel : public menus::SimpleMenuModel {
public:
- explicit TabMenuModel(menus::SimpleMenuModel::Delegate* delegate);
+ TabMenuModel(menus::SimpleMenuModel::Delegate* delegate, bool is_pinned);
virtual ~TabMenuModel() {}
private:
- void Build();
+ void Build(bool is_pinned);
DISALLOW_COPY_AND_ASSIGN(TabMenuModel);
};
« no previous file with comments | « chrome/browser/gtk/tabs/tab_gtk.cc ('k') | chrome/browser/tab_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698