| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Multiply-included message header, no traditional include guard. | 5 // Multiply-included message header, no traditional include guard. |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/process/process.h" | 10 #include "base/process/process.h" |
| 11 #include "content/common/content_export.h" | 11 #include "content/common/content_export.h" |
| 12 #include "content/common/content_param_traits.h" | 12 #include "content/common/content_param_traits.h" |
| 13 #include "content/common/cursors/webcursor.h" | 13 #include "content/common/cursors/webcursor.h" |
| 14 #include "content/common/edit_command.h" | 14 #include "content/common/edit_command.h" |
| 15 #include "content/common/frame_param_macros.h" | 15 #include "content/common/frame_param_macros.h" |
| 16 #include "content/public/common/common_param_traits.h" | 16 #include "content/public/common/common_param_traits.h" |
| 17 #include "content/public/common/drop_data.h" | 17 #include "content/public/common/drop_data.h" |
| 18 #include "ipc/ipc_channel_handle.h" | 18 #include "ipc/ipc_channel_handle.h" |
| 19 #include "ipc/ipc_message_macros.h" | 19 #include "ipc/ipc_message_macros.h" |
| 20 #include "ipc/ipc_message_utils.h" | 20 #include "ipc/ipc_message_utils.h" |
| 21 #include "third_party/WebKit/public/platform/WebFocusType.h" |
| 21 #include "third_party/WebKit/public/web/WebCompositionUnderline.h" | 22 #include "third_party/WebKit/public/web/WebCompositionUnderline.h" |
| 22 #include "third_party/WebKit/public/web/WebDragOperation.h" | 23 #include "third_party/WebKit/public/web/WebDragOperation.h" |
| 23 #include "third_party/WebKit/public/web/WebDragStatus.h" | 24 #include "third_party/WebKit/public/web/WebDragStatus.h" |
| 24 #include "third_party/skia/include/core/SkBitmap.h" | 25 #include "third_party/skia/include/core/SkBitmap.h" |
| 25 #include "ui/gfx/geometry/point.h" | 26 #include "ui/gfx/geometry/point.h" |
| 26 #include "ui/gfx/geometry/rect.h" | 27 #include "ui/gfx/geometry/rect.h" |
| 27 #include "ui/gfx/geometry/size.h" | 28 #include "ui/gfx/geometry/size.h" |
| 28 #include "ui/gfx/ipc/gfx_param_traits.h" | 29 #include "ui/gfx/ipc/gfx_param_traits.h" |
| 29 #include "url/gurl.h" | 30 #include "url/gurl.h" |
| 30 | 31 |
| 31 #undef IPC_MESSAGE_EXPORT | 32 #undef IPC_MESSAGE_EXPORT |
| 32 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT | 33 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT |
| 33 | 34 |
| 34 #define IPC_MESSAGE_START BrowserPluginMsgStart | 35 #define IPC_MESSAGE_START BrowserPluginMsgStart |
| 35 | 36 |
| 36 | 37 |
| 37 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebDragStatus, blink::WebDragStatusLast) | 38 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebDragStatus, blink::WebDragStatusLast) |
| 39 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebFocusType, blink::WebFocusTypeLast) |
| 38 | 40 |
| 39 IPC_STRUCT_BEGIN(BrowserPluginHostMsg_ResizeGuest_Params) | 41 IPC_STRUCT_BEGIN(BrowserPluginHostMsg_ResizeGuest_Params) |
| 40 // The new size of guest view. | 42 // The new size of guest view. |
| 41 IPC_STRUCT_MEMBER(gfx::Size, view_size) | 43 IPC_STRUCT_MEMBER(gfx::Size, view_size) |
| 42 // Indicates the scale factor of the embedder WebView. | 44 // Indicates the scale factor of the embedder WebView. |
| 43 IPC_STRUCT_MEMBER(float, scale_factor) | 45 IPC_STRUCT_MEMBER(float, scale_factor) |
| 44 // Indicates a request for a full repaint of the page. | 46 // Indicates a request for a full repaint of the page. |
| 45 // This is required for switching from compositing to the software | 47 // This is required for switching from compositing to the software |
| 46 // rendering path. | 48 // rendering path. |
| 47 IPC_STRUCT_MEMBER(bool, repaint) | 49 IPC_STRUCT_MEMBER(bool, repaint) |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 104 int /* browser_plugin_instance_id */, | 106 int /* browser_plugin_instance_id */, |
| 105 BrowserPluginHostMsg_Attach_Params /* params */) | 107 BrowserPluginHostMsg_Attach_Params /* params */) |
| 106 | 108 |
| 107 // This message is sent to the browser process to indicate that the | 109 // This message is sent to the browser process to indicate that the |
| 108 // BrowserPlugin identified by |browser_plugin_instance_id| will no longer serve | 110 // BrowserPlugin identified by |browser_plugin_instance_id| will no longer serve |
| 109 // as a container for a guest. | 111 // as a container for a guest. |
| 110 IPC_MESSAGE_ROUTED1(BrowserPluginHostMsg_Detach, | 112 IPC_MESSAGE_ROUTED1(BrowserPluginHostMsg_Detach, |
| 111 int /* browser_plugin_instance_id */) | 113 int /* browser_plugin_instance_id */) |
| 112 | 114 |
| 113 // Tells the guest to focus or defocus itself. | 115 // Tells the guest to focus or defocus itself. |
| 114 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_SetFocus, | 116 IPC_MESSAGE_ROUTED3(BrowserPluginHostMsg_SetFocus, |
| 115 int /* browser_plugin_instance_id */, | 117 int /* browser_plugin_instance_id */, |
| 116 bool /* enable */) | 118 bool /* enable */, |
| 119 blink::WebFocusType /* focus_type */) |
| 117 | 120 |
| 118 // Sends an input event to the guest. | 121 // Sends an input event to the guest. |
| 119 IPC_MESSAGE_ROUTED3(BrowserPluginHostMsg_HandleInputEvent, | 122 IPC_MESSAGE_ROUTED3(BrowserPluginHostMsg_HandleInputEvent, |
| 120 int /* browser_plugin_instance_id */, | 123 int /* browser_plugin_instance_id */, |
| 121 gfx::Rect /* guest_window_rect */, | 124 gfx::Rect /* guest_window_rect */, |
| 122 IPC::WebInputEventPointer /* event */) | 125 IPC::WebInputEventPointer /* event */) |
| 123 | 126 |
| 124 // Notify the guest renderer that some resources given to the embededer | 127 // Notify the guest renderer that some resources given to the embededer |
| 125 // are not used any more. | 128 // are not used any more. |
| 126 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_ReclaimCompositorResources, | 129 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_ReclaimCompositorResources, |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 205 | 208 |
| 206 // Sends text to be displayed in tooltip. | 209 // Sends text to be displayed in tooltip. |
| 207 IPC_MESSAGE_CONTROL2(BrowserPluginMsg_SetTooltipText, | 210 IPC_MESSAGE_CONTROL2(BrowserPluginMsg_SetTooltipText, |
| 208 int /* browser_plugin_instance_id */, | 211 int /* browser_plugin_instance_id */, |
| 209 base::string16 /* tooltip_text */) | 212 base::string16 /* tooltip_text */) |
| 210 | 213 |
| 211 // Acknowledge that we presented an ubercomp frame. | 214 // Acknowledge that we presented an ubercomp frame. |
| 212 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_CompositorFrameSwappedACK, | 215 IPC_MESSAGE_ROUTED2(BrowserPluginHostMsg_CompositorFrameSwappedACK, |
| 213 int /* browser_plugin_instance_id */, | 216 int /* browser_plugin_instance_id */, |
| 214 FrameHostMsg_CompositorFrameSwappedACK_Params /* params */) | 217 FrameHostMsg_CompositorFrameSwappedACK_Params /* params */) |
| OLD | NEW |