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

Side by Side Diff: webkit/glue/context_menu.h

Issue 6253017: Pepper/Flapper: First pass at context menu implementation. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: make brettw happier Created 9 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « ppapi/ppapi_cpp.gypi ('k') | webkit/glue/context_menu.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) 2006-2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2009 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 WEBKIT_GLUE_CONTEXT_MENU_H_ 5 #ifndef WEBKIT_GLUE_CONTEXT_MENU_H_
6 #define WEBKIT_GLUE_CONTEXT_MENU_H_ 6 #define WEBKIT_GLUE_CONTEXT_MENU_H_
7 7
8 #include <vector> 8 #include <vector>
9 9
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "base/string16.h" 11 #include "base/string16.h"
12 #include "googleurl/src/gurl.h" 12 #include "googleurl/src/gurl.h"
13 #include "webkit/glue/webmenuitem.h" 13 #include "webkit/glue/webmenuitem.h"
14 14
15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebContextMenuData.h" 15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebContextMenuData.h"
16 16
17 namespace webkit_glue {
18
19 struct CustomContextMenuContext {
20 bool is_pepper_menu;
21 int request_id;
22
23 CustomContextMenuContext();
24 };
25
26 } // namespace webkit_glue
27
28 // TODO(viettrungluu): Put this in the webkit_glue namespace.
17 // Parameters structure for ViewHostMsg_ContextMenu. 29 // Parameters structure for ViewHostMsg_ContextMenu.
18 // FIXME(beng): This would be more useful in the future and more efficient 30 // FIXME(beng): This would be more useful in the future and more efficient
19 // if the parameters here weren't so literally mapped to what 31 // if the parameters here weren't so literally mapped to what
20 // they contain for the ContextMenu task. It might be better 32 // they contain for the ContextMenu task. It might be better
21 // to make the string fields more generic so that this object 33 // to make the string fields more generic so that this object
22 // could be used for more contextual actions. 34 // could be used for more contextual actions.
23 struct ContextMenuParams { 35 struct ContextMenuParams {
24 // This is the type of Context Node that the context menu was invoked on. 36 // This is the type of Context Node that the context menu was invoked on.
25 WebKit::WebContextMenuData::MediaType media_type; 37 WebKit::WebContextMenuData::MediaType media_type;
26 38
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 // These flags indicate to the browser whether the renderer believes it is 99 // These flags indicate to the browser whether the renderer believes it is
88 // able to perform the corresponding action. 100 // able to perform the corresponding action.
89 int edit_flags; 101 int edit_flags;
90 102
91 // The security info for the resource we are showing the menu on. 103 // The security info for the resource we are showing the menu on.
92 std::string security_info; 104 std::string security_info;
93 105
94 // The character encoding of the frame on which the menu is invoked. 106 // The character encoding of the frame on which the menu is invoked.
95 std::string frame_charset; 107 std::string frame_charset;
96 108
109 webkit_glue::CustomContextMenuContext custom_context;
97 std::vector<WebMenuItem> custom_items; 110 std::vector<WebMenuItem> custom_items;
98 111
99 ContextMenuParams(); 112 ContextMenuParams();
100 ContextMenuParams(const WebKit::WebContextMenuData& data); 113 ContextMenuParams(const WebKit::WebContextMenuData& data);
101 ~ContextMenuParams(); 114 ~ContextMenuParams();
102 }; 115 };
103 116
104 #endif // WEBKIT_GLUE_CONTEXT_MENU_H_ 117 #endif // WEBKIT_GLUE_CONTEXT_MENU_H_
OLDNEW
« no previous file with comments | « ppapi/ppapi_cpp.gypi ('k') | webkit/glue/context_menu.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698