summaryrefslogtreecommitdiffstats
path: root/chrome/browser/tab_menu_model.h
diff options
context:
space:
mode:
authorpinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-16 16:21:36 +0000
committerpinkerton@chromium.org <pinkerton@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2009-12-16 16:21:36 +0000
commitf8a0cb584078998db374e3df2e0f4290377b0be6 (patch)
tree3c32b4283e37d37d07dd9dc6737efa4e7e4d7ec3 /chrome/browser/tab_menu_model.h
parent5db3af57ca8994249f0ba0efbb60ac103f7f0934 (diff)
downloadchromium_src-f8a0cb584078998db374e3df2e0f4290377b0be6.zip
chromium_src-f8a0cb584078998db374e3df2e0f4290377b0be6.tar.gz
chromium_src-f8a0cb584078998db374e3df2e0f4290377b0be6.tar.bz2
Factor tab context menu into a shared model and fix mac and win to use it. Improve a couple of model unit tests. Remove unused members in the models.
BUG=28977 TEST=context menus on tabs should work and enable/disable properly Review URL: http://codereview.chromium.org/500030 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34718 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/browser/tab_menu_model.h')
-rw-r--r--chrome/browser/tab_menu_model.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/chrome/browser/tab_menu_model.h b/chrome/browser/tab_menu_model.h
new file mode 100644
index 0000000..d176fc9
--- /dev/null
+++ b/chrome/browser/tab_menu_model.h
@@ -0,0 +1,25 @@
+// Copyright (c) 2009 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.
+
+#ifndef CHROME_BROWSER_TAB_MENU_MODEL_H_
+#define CHROME_BROWSER_TAB_MENU_MODEL_H_
+
+#include "app/menus/simple_menu_model.h"
+
+class Browser;
+
+// A menu model that builds the contents of the tab context menu. This menu has
+// only one level (no submenus).
+class TabMenuModel : public menus::SimpleMenuModel {
+ public:
+ explicit TabMenuModel(menus::SimpleMenuModel::Delegate* delegate);
+ virtual ~TabMenuModel() { }
+
+ private:
+ void Build();
+
+ DISALLOW_COPY_AND_ASSIGN(TabMenuModel);
+};
+
+#endif // CHROME_BROWSER_TAB_MENU_MODEL_H_