diff options
author | pfeldman@chromium.org <pfeldman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-09 14:36:33 +0000 |
---|---|---|
committer | pfeldman@chromium.org <pfeldman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-12-09 14:36:33 +0000 |
commit | a0c7153edf226726a86619119c68f5e660b3930e (patch) | |
tree | 97ea32cf90057ed1c75c45e3c3f6718f12e67a6b /webkit/glue/context_menu.h | |
parent | 33db7e323b9d6d1bd8cda94bc3fe5da1727c485a (diff) | |
download | chromium_src-a0c7153edf226726a86619119c68f5e660b3930e.zip chromium_src-a0c7153edf226726a86619119c68f5e660b3930e.tar.gz chromium_src-a0c7153edf226726a86619119c68f5e660b3930e.tar.bz2 |
Chromium: support custom WebCore context menu items in Chromium port (downstream).
Review URL: http://codereview.chromium.org/465123
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@34154 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'webkit/glue/context_menu.h')
-rw-r--r-- | webkit/glue/context_menu.h | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/webkit/glue/context_menu.h b/webkit/glue/context_menu.h index 87825f4..b1744df 100644 --- a/webkit/glue/context_menu.h +++ b/webkit/glue/context_menu.h @@ -10,6 +10,8 @@ #include "base/basictypes.h" #include "base/string_util.h" #include "googleurl/src/gurl.h" +#include "webkit/glue/webmenuitem.h" + #include "third_party/WebKit/WebKit/chromium/public/WebContextMenuData.h" // Parameters structure for ViewHostMsg_ContextMenu. @@ -81,6 +83,8 @@ struct ContextMenuParams { // The character encoding of the frame on which the menu is invoked. std::string frame_charset; + std::vector<WebMenuItem> custom_items; + ContextMenuParams() {} ContextMenuParams(const WebKit::WebContextMenuData& data) @@ -99,7 +103,10 @@ struct ContextMenuParams { is_editable(data.isEditable), edit_flags(data.editFlags), security_info(data.securityInfo), - frame_charset(data.frameEncoding.utf8()) {} + frame_charset(data.frameEncoding.utf8()) { + for (size_t i = 0; i < data.customItems.size(); ++i) + custom_items.push_back(WebMenuItem(data.customItems[i])); + } }; #endif // WEBKIT_GLUE_CONTEXT_MENU_H_ |