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

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

Issue 8741006: Add exports needed for glue to build as a component. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase to r112585 Created 9 years 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 | « webkit/glue/alt_error_page_resource_fetcher.h ('k') | webkit/glue/cpp_binding_example.h » ('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) 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 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/webkit_glue_export.h"
13 #include "webkit/glue/webmenuitem.h" 14 #include "webkit/glue/webmenuitem.h"
14 15
15 #include "third_party/WebKit/Source/WebKit/chromium/public/WebContextMenuData.h" 16 #include "third_party/WebKit/Source/WebKit/chromium/public/WebContextMenuData.h"
16 17
17 namespace webkit_glue { 18 namespace webkit_glue {
18 19
19 struct CustomContextMenuContext { 20 struct CustomContextMenuContext {
20 bool is_pepper_menu; 21 bool is_pepper_menu;
21 int request_id; 22 int request_id;
22 // The routing ID of the render widget on which the context menu is shown. 23 // The routing ID of the render widget on which the context menu is shown.
23 // It could also be |kCurrentRenderWidget|, which means the render widget that 24 // It could also be |kCurrentRenderWidget|, which means the render widget that
24 // the corresponding ViewHostMsg_ContextMenu is sent to. 25 // the corresponding ViewHostMsg_ContextMenu is sent to.
25 int32 render_widget_id; 26 int32 render_widget_id;
26 static const int32 kCurrentRenderWidget; 27 static const int32 kCurrentRenderWidget;
27 28
28 CustomContextMenuContext(); 29 WEBKIT_GLUE_EXPORT CustomContextMenuContext();
29 }; 30 };
30 31
31 } // namespace webkit_glue 32 } // namespace webkit_glue
32 33
33 // TODO(viettrungluu): Put this in the webkit_glue namespace. 34 // TODO(viettrungluu): Put this in the webkit_glue namespace.
34 // Parameters structure for ViewHostMsg_ContextMenu. 35 // Parameters structure for ViewHostMsg_ContextMenu.
35 // FIXME(beng): This would be more useful in the future and more efficient 36 // FIXME(beng): This would be more useful in the future and more efficient
36 // if the parameters here weren't so literally mapped to what 37 // if the parameters here weren't so literally mapped to what
37 // they contain for the ContextMenu task. It might be better 38 // they contain for the ContextMenu task. It might be better
38 // to make the string fields more generic so that this object 39 // to make the string fields more generic so that this object
39 // could be used for more contextual actions. 40 // could be used for more contextual actions.
40 struct ContextMenuParams { 41 struct WEBKIT_GLUE_EXPORT ContextMenuParams {
41 // This is the type of Context Node that the context menu was invoked on. 42 // This is the type of Context Node that the context menu was invoked on.
42 WebKit::WebContextMenuData::MediaType media_type; 43 WebKit::WebContextMenuData::MediaType media_type;
43 44
44 // These values represent the coordinates of the mouse when the context menu 45 // These values represent the coordinates of the mouse when the context menu
45 // was invoked. Coords are relative to the associated RenderView's origin. 46 // was invoked. Coords are relative to the associated RenderView's origin.
46 int x; 47 int x;
47 int y; 48 int y;
48 49
49 // This is the URL of the link that encloses the node the context menu was 50 // This is the URL of the link that encloses the node the context menu was
50 // invoked on. 51 // invoked on.
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
127 128
128 webkit_glue::CustomContextMenuContext custom_context; 129 webkit_glue::CustomContextMenuContext custom_context;
129 std::vector<WebMenuItem> custom_items; 130 std::vector<WebMenuItem> custom_items;
130 131
131 ContextMenuParams(); 132 ContextMenuParams();
132 ContextMenuParams(const WebKit::WebContextMenuData& data); 133 ContextMenuParams(const WebKit::WebContextMenuData& data);
133 ~ContextMenuParams(); 134 ~ContextMenuParams();
134 }; 135 };
135 136
136 #endif // WEBKIT_GLUE_CONTEXT_MENU_H_ 137 #endif // WEBKIT_GLUE_CONTEXT_MENU_H_
OLDNEW
« no previous file with comments | « webkit/glue/alt_error_page_resource_fetcher.h ('k') | webkit/glue/cpp_binding_example.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698