Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 // IPC messages for interacting with frames. | 5 // IPC messages for interacting with frames. |
| 6 // Multiply-included message file, hence no include guard. | 6 // Multiply-included message file, hence no include guard. |
| 7 | 7 |
| 8 #include "content/common/content_export.h" | 8 #include "content/common/content_export.h" |
| 9 #include "content/common/frame_param.h" | |
| 9 #include "content/public/common/common_param_traits.h" | 10 #include "content/public/common/common_param_traits.h" |
| 10 #include "ipc/ipc_message_macros.h" | 11 #include "ipc/ipc_message_macros.h" |
| 12 #include "url/gurl.h" | |
| 11 | 13 |
| 12 #undef IPC_MESSAGE_EXPORT | 14 #undef IPC_MESSAGE_EXPORT |
| 13 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT | 15 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT |
| 14 | 16 |
| 15 #define IPC_MESSAGE_START FrameMsgStart | 17 #define IPC_MESSAGE_START FrameMsgStart |
| 16 | 18 |
| 19 // ----------------------------------------------------------------------------- | |
| 20 // Messages sent from the browser to the renderer. | |
| 21 | |
| 22 // When HW accelerated buffers are swapped in an out-of-process child frame | |
| 23 // renderer, the message is forwarded to the top level frame renderer to | |
|
nasko
2013/12/20 17:21:05
Is it really the top level or the parent? I though
awong
2013/12/20 23:53:38
Erp...I think this is a naming collosion. "frame r
| |
| 24 // notify it of a new texture available for compositing. | |
| 25 IPC_MESSAGE_ROUTED1(FrameMsg_BuffersSwapped, | |
| 26 FrameMsg_BuffersSwapped_Params /* params */) | |
| 27 | |
| 28 IPC_MESSAGE_ROUTED1(FrameMsg_CompositorFrameSwapped, | |
|
nasko
2013/12/20 17:21:05
nit: It will be nice to have a comment on this IPC
awong
2013/12/20 23:53:38
Done.
| |
| 29 FrameMsg_CompositorFrameSwapped_Params /* params */) | |
| 30 | |
| 31 // ----------------------------------------------------------------------------- | |
| 32 // Messages sent from the renderer to the browser. | |
| 33 | |
| 17 // Sent by the renderer when a child frame is created in the renderer. The | 34 // Sent by the renderer when a child frame is created in the renderer. The |
| 18 // |parent_frame_id| and |frame_id| are NOT routing ids. They are | 35 // |parent_frame_id| and |frame_id| are NOT routing ids. They are |
| 19 // renderer-allocated identifiers used for tracking a frame's creation. | 36 // renderer-allocated identifiers used for tracking a frame's creation. |
| 20 // | 37 // |
| 21 // Each of these messages will have a corresponding FrameHostMsg_Detach message | 38 // Each of these messages will have a corresponding FrameHostMsg_Detach message |
| 22 // sent when the frame is detached from the DOM. | 39 // sent when the frame is detached from the DOM. |
| 23 // | 40 // |
| 24 // TOOD(ajwong): replace parent_render_frame_id and frame_id with just the | 41 // TOOD(ajwong): replace parent_render_frame_id and frame_id with just the |
| 25 // routing ids. | 42 // routing ids. |
| 26 IPC_SYNC_MESSAGE_CONTROL4_1(FrameHostMsg_CreateChildFrame, | 43 IPC_SYNC_MESSAGE_CONTROL4_1(FrameHostMsg_CreateChildFrame, |
| (...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 78 // create a plugin. The browser will create the plugin process if | 95 // create a plugin. The browser will create the plugin process if |
| 79 // necessary, and will return a handle to the channel on success. | 96 // necessary, and will return a handle to the channel on success. |
| 80 // On error an empty string is returned. | 97 // On error an empty string is returned. |
| 81 IPC_SYNC_MESSAGE_CONTROL4_2(FrameHostMsg_OpenChannelToPlugin, | 98 IPC_SYNC_MESSAGE_CONTROL4_2(FrameHostMsg_OpenChannelToPlugin, |
| 82 int /* render_frame_id */, | 99 int /* render_frame_id */, |
| 83 GURL /* url */, | 100 GURL /* url */, |
| 84 GURL /* page_url */, | 101 GURL /* page_url */, |
| 85 std::string /* mime_type */, | 102 std::string /* mime_type */, |
| 86 IPC::ChannelHandle /* channel_handle */, | 103 IPC::ChannelHandle /* channel_handle */, |
| 87 content::WebPluginInfo /* info */) | 104 content::WebPluginInfo /* info */) |
| 105 | |
| 106 // Acknowledge that we presented a HW buffer and provide a sync point | |
| 107 // to specify the location in the command stream when the compositor | |
| 108 // is no longer using it. | |
| 109 IPC_MESSAGE_ROUTED1(FrameHostMsg_BuffersSwappedACK, | |
| 110 FrameHostMsg_BuffersSwappedACK_Params /* params */) | |
| 111 | |
| 112 // Acknowledge that we presented an ubercomp frame. | |
| 113 IPC_MESSAGE_ROUTED1(FrameHostMsg_CompositorFrameSwappedACK, | |
| 114 FrameHostMsg_CompositorFrameSwappedACK_Params /* params */) | |
| 115 | |
| OLD | NEW |