OLD | NEW |
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_API_H__ | 5 #ifndef CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_API_H__ |
6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_API_H__ | 6 #define CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_API_H__ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "chrome/browser/extensions/extension_function.h" | 9 #include "chrome/browser/extensions/extension_function.h" |
10 #include "chrome/browser/extensions/extension_menu_manager.h" | 10 #include "chrome/browser/extensions/extension_menu_manager.h" |
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
57 // parentId key is not in properties, this will return true and leave |result| | 57 // parentId key is not in properties, this will return true and leave |result| |
58 // unset. Also, it is considered an error if the item found has a type other | 58 // unset. Also, it is considered an error if the item found has a type other |
59 // than NORMAL. | 59 // than NORMAL. |
60 bool GetParent(const base::DictionaryValue& properties, | 60 bool GetParent(const base::DictionaryValue& properties, |
61 const ExtensionMenuManager& manager, | 61 const ExtensionMenuManager& manager, |
62 ExtensionMenuItem** result); | 62 ExtensionMenuItem** result); |
63 }; | 63 }; |
64 | 64 |
65 class CreateContextMenuFunction : public ExtensionContextMenuFunction { | 65 class CreateContextMenuFunction : public ExtensionContextMenuFunction { |
66 virtual ~CreateContextMenuFunction() {} | 66 virtual ~CreateContextMenuFunction() {} |
67 virtual bool RunImpl(); | 67 virtual bool RunImpl() OVERRIDE; |
68 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.create") | 68 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.create") |
69 }; | 69 }; |
70 | 70 |
71 class UpdateContextMenuFunction : public ExtensionContextMenuFunction { | 71 class UpdateContextMenuFunction : public ExtensionContextMenuFunction { |
72 virtual ~UpdateContextMenuFunction() {} | 72 virtual ~UpdateContextMenuFunction() {} |
73 virtual bool RunImpl(); | 73 virtual bool RunImpl() OVERRIDE; |
74 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.update") | 74 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.update") |
75 }; | 75 }; |
76 | 76 |
77 class RemoveContextMenuFunction : public ExtensionContextMenuFunction { | 77 class RemoveContextMenuFunction : public ExtensionContextMenuFunction { |
78 virtual ~RemoveContextMenuFunction() {} | 78 virtual ~RemoveContextMenuFunction() {} |
79 virtual bool RunImpl(); | 79 virtual bool RunImpl() OVERRIDE; |
80 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.remove") | 80 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.remove") |
81 }; | 81 }; |
82 | 82 |
83 class RemoveAllContextMenusFunction : public ExtensionContextMenuFunction { | 83 class RemoveAllContextMenusFunction : public ExtensionContextMenuFunction { |
84 virtual ~RemoveAllContextMenusFunction() {} | 84 virtual ~RemoveAllContextMenusFunction() {} |
85 virtual bool RunImpl(); | 85 virtual bool RunImpl() OVERRIDE; |
86 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.removeAll") | 86 DECLARE_EXTENSION_FUNCTION_NAME("contextMenus.removeAll") |
87 }; | 87 }; |
88 | 88 |
89 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_API_H__ | 89 #endif // CHROME_BROWSER_EXTENSIONS_EXTENSION_CONTEXT_MENU_API_H__ |
OLD | NEW |