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

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

Issue 8473003: Add OVERRIDE to chrome/browser/extensions/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 years, 1 month 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 27 matching lines...) Expand all
38 // Creates a menu model for the given extension action. If 38 // Creates a menu model for the given extension action. If
39 // prefs::kExtensionsUIDeveloperMode is enabled then a menu item 39 // prefs::kExtensionsUIDeveloperMode is enabled then a menu item
40 // will be shown for "Inspect Popup" which, when selected, will cause 40 // will be shown for "Inspect Popup" which, when selected, will cause
41 // ShowPopupForDevToolsWindow() to be called on |delegate|. 41 // ShowPopupForDevToolsWindow() to be called on |delegate|.
42 ExtensionContextMenuModel(const Extension* extension, 42 ExtensionContextMenuModel(const Extension* extension,
43 Browser* browser, 43 Browser* browser,
44 PopupDelegate* delegate); 44 PopupDelegate* delegate);
45 virtual ~ExtensionContextMenuModel(); 45 virtual ~ExtensionContextMenuModel();
46 46
47 // SimpleMenuModel::Delegate overrides. 47 // SimpleMenuModel::Delegate overrides.
48 virtual bool IsCommandIdChecked(int command_id) const; 48 virtual bool IsCommandIdChecked(int command_id) const OVERRIDE;
49 virtual bool IsCommandIdEnabled(int command_id) const; 49 virtual bool IsCommandIdEnabled(int command_id) const OVERRIDE;
50 virtual bool GetAcceleratorForCommandId(int command_id, 50 virtual bool GetAcceleratorForCommandId(
51 ui::Accelerator* accelerator); 51 int command_id,
52 virtual void ExecuteCommand(int command_id); 52 ui::Accelerator* accelerator) OVERRIDE;
53 virtual void ExecuteCommand(int command_id) OVERRIDE;
53 54
54 // ExtensionUninstallDialog::Delegate: 55 // ExtensionUninstallDialog::Delegate:
55 virtual void ExtensionUninstallAccepted(); 56 virtual void ExtensionUninstallAccepted() OVERRIDE;
56 virtual void ExtensionUninstallCanceled(); 57 virtual void ExtensionUninstallCanceled() OVERRIDE;
57 58
58 private: 59 private:
59 void InitCommonCommands(); 60 void InitCommonCommands();
60 61
61 // Gets the extension we are displaying the menu for. Returns NULL if the 62 // Gets the extension we are displaying the menu for. Returns NULL if the
62 // extension has been uninstalled and no longer exists. 63 // extension has been uninstalled and no longer exists.
63 const Extension* GetExtension() const; 64 const Extension* GetExtension() const;
64 65
65 // A copy of the extension's id. 66 // A copy of the extension's id.
66 std::string extension_id_; 67 std::string extension_id_;
67 68
68 // The extension action we are displaying the menu for (or NULL). 69 // The extension action we are displaying the menu for (or NULL).
69 ExtensionAction* extension_action_; 70 ExtensionAction* extension_action_;
70 71
71 Browser* browser_; 72 Browser* browser_;
72 73
73 Profile* profile_; 74 Profile* profile_;
74 75
75 // The delegate which handles the 'inspect popup' menu command (or NULL). 76 // The delegate which handles the 'inspect popup' menu command (or NULL).
76 PopupDelegate* delegate_; 77 PopupDelegate* delegate_;
77 78
78 // Keeps track of the extension uninstall dialog. 79 // Keeps track of the extension uninstall dialog.
79 scoped_ptr<ExtensionUninstallDialog> extension_uninstall_dialog_; 80 scoped_ptr<ExtensionUninstallDialog> extension_uninstall_dialog_;
80 81
81 DISALLOW_COPY_AND_ASSIGN(ExtensionContextMenuModel); 82 DISALLOW_COPY_AND_ASSIGN(ExtensionContextMenuModel);
82 }; 83 };
83 84
84 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_ 85 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_MODEL_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_context_menu_api.h ('k') | chrome/browser/extensions/extension_cookies_api.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698