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

Side by Side Diff: chrome/browser/extensions/extension_context_menu_model.h

Issue 476873002: Make hiding an extension action cause it to go to the overflow menu (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase 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 unified diff | Download patch
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_context_menu_model.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_ 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_
7 7
8 #include <string> 8 #include <string>
9 9
10 #include "base/memory/scoped_ptr.h" 10 #include "base/memory/scoped_ptr.h"
(...skipping 17 matching lines...) Expand all
28 // The context menu model for extension icons. 28 // The context menu model for extension icons.
29 class ExtensionContextMenuModel 29 class ExtensionContextMenuModel
30 : public base::RefCounted<ExtensionContextMenuModel>, 30 : public base::RefCounted<ExtensionContextMenuModel>,
31 public ui::SimpleMenuModel, 31 public ui::SimpleMenuModel,
32 public ui::SimpleMenuModel::Delegate, 32 public ui::SimpleMenuModel::Delegate,
33 public extensions::ExtensionUninstallDialog::Delegate { 33 public extensions::ExtensionUninstallDialog::Delegate {
34 public: 34 public:
35 enum MenuEntries { 35 enum MenuEntries {
36 NAME = 0, 36 NAME = 0,
37 CONFIGURE, 37 CONFIGURE,
38 HIDE, 38 TOGGLE_VISIBILITY,
39 UNINSTALL, 39 UNINSTALL,
40 MANAGE, 40 MANAGE,
41 INSPECT_POPUP, 41 INSPECT_POPUP,
42 ALWAYS_RUN 42 ALWAYS_RUN
43 }; 43 };
44 44
45 // Type of action the extension icon represents. 45 // Type of action the extension icon represents.
46 enum ActionType { NO_ACTION = 0, BROWSER_ACTION, PAGE_ACTION }; 46 enum ActionType { NO_ACTION = 0, BROWSER_ACTION, PAGE_ACTION };
47 47
48 // Delegate to handle showing an ExtensionAction popup. 48 // Delegate to handle showing an ExtensionAction popup.
(...skipping 74 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 // Menu matcher for context menu items specified by the extension. 123 // Menu matcher for context menu items specified by the extension.
124 scoped_ptr<extensions::ContextMenuMatcher> extension_items_; 124 scoped_ptr<extensions::ContextMenuMatcher> extension_items_;
125 125
126 // Number of extension items in this menu. Used for testing. 126 // Number of extension items in this menu. Used for testing.
127 int extension_items_count_; 127 int extension_items_count_;
128 128
129 DISALLOW_COPY_AND_ASSIGN(ExtensionContextMenuModel); 129 DISALLOW_COPY_AND_ASSIGN(ExtensionContextMenuModel);
130 }; 130 };
131 131
132 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_ 132 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/extensions/extension_context_menu_model.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698