| 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/content_param_traits.h" | 9 #include "content/common/content_param_traits.h" |
| 10 #include "content/common/frame_message_enums.h" | 10 #include "content/common/frame_message_enums.h" |
| (...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 217 IPC_STRUCT_TRAITS_END() | 217 IPC_STRUCT_TRAITS_END() |
| 218 | 218 |
| 219 IPC_STRUCT_TRAITS_BEGIN(content::BeginNavigationParams) | 219 IPC_STRUCT_TRAITS_BEGIN(content::BeginNavigationParams) |
| 220 IPC_STRUCT_TRAITS_MEMBER(method) | 220 IPC_STRUCT_TRAITS_MEMBER(method) |
| 221 IPC_STRUCT_TRAITS_MEMBER(headers) | 221 IPC_STRUCT_TRAITS_MEMBER(headers) |
| 222 IPC_STRUCT_TRAITS_MEMBER(load_flags) | 222 IPC_STRUCT_TRAITS_MEMBER(load_flags) |
| 223 IPC_STRUCT_TRAITS_MEMBER(has_user_gesture) | 223 IPC_STRUCT_TRAITS_MEMBER(has_user_gesture) |
| 224 IPC_STRUCT_TRAITS_END() | 224 IPC_STRUCT_TRAITS_END() |
| 225 | 225 |
| 226 IPC_STRUCT_TRAITS_BEGIN(content::CommitNavigationParams) | 226 IPC_STRUCT_TRAITS_BEGIN(content::CommitNavigationParams) |
| 227 IPC_STRUCT_TRAITS_MEMBER(page_state) | |
| 228 IPC_STRUCT_TRAITS_MEMBER(is_overriding_user_agent) | 227 IPC_STRUCT_TRAITS_MEMBER(is_overriding_user_agent) |
| 229 IPC_STRUCT_TRAITS_MEMBER(browser_navigation_start) | 228 IPC_STRUCT_TRAITS_MEMBER(browser_navigation_start) |
| 230 IPC_STRUCT_TRAITS_END() | 229 IPC_STRUCT_TRAITS_END() |
| 231 | 230 |
| 231 IPC_STRUCT_TRAITS_BEGIN(content::HistoryNavigationParams) |
| 232 IPC_STRUCT_TRAITS_MEMBER(page_state) |
| 233 IPC_STRUCT_TRAITS_MEMBER(page_id) |
| 234 IPC_STRUCT_TRAITS_MEMBER(pending_history_list_offset) |
| 235 IPC_STRUCT_TRAITS_MEMBER(current_history_list_offset) |
| 236 IPC_STRUCT_TRAITS_MEMBER(current_history_list_length) |
| 237 IPC_STRUCT_TRAITS_MEMBER(should_clear_history_list) |
| 238 IPC_STRUCT_TRAITS_END() |
| 239 |
| 232 IPC_STRUCT_TRAITS_BEGIN(content::FrameReplicationState) | 240 IPC_STRUCT_TRAITS_BEGIN(content::FrameReplicationState) |
| 233 IPC_STRUCT_TRAITS_MEMBER(origin) | 241 IPC_STRUCT_TRAITS_MEMBER(origin) |
| 234 IPC_STRUCT_TRAITS_MEMBER(sandbox_flags) | 242 IPC_STRUCT_TRAITS_MEMBER(sandbox_flags) |
| 235 IPC_STRUCT_TRAITS_MEMBER(name) | 243 IPC_STRUCT_TRAITS_MEMBER(name) |
| 236 IPC_STRUCT_TRAITS_END() | 244 IPC_STRUCT_TRAITS_END() |
| 237 | 245 |
| 238 IPC_STRUCT_BEGIN(FrameMsg_NewFrame_WidgetParams) | 246 IPC_STRUCT_BEGIN(FrameMsg_NewFrame_WidgetParams) |
| 239 // Gives the routing ID for the RenderWidget that will be attached to the | 247 // Gives the routing ID for the RenderWidget that will be attached to the |
| 240 // new RenderFrame. If the RenderFrame does not need a RenderWidget, this | 248 // new RenderFrame. If the RenderFrame does not need a RenderWidget, this |
| 241 // is MSG_ROUTING_NONE and the other parameters are not read. | 249 // is MSG_ROUTING_NONE and the other parameters are not read. |
| 242 IPC_STRUCT_MEMBER(int, routing_id) | 250 IPC_STRUCT_MEMBER(int, routing_id) |
| 243 | 251 |
| 244 // Identifier for the output surface for the new RenderWidget. | 252 // Identifier for the output surface for the new RenderWidget. |
| 245 IPC_STRUCT_MEMBER(int, surface_id) | 253 IPC_STRUCT_MEMBER(int, surface_id) |
| 246 | 254 |
| 247 // Tells the new RenderWidget whether it is initially hidden. | 255 // Tells the new RenderWidget whether it is initially hidden. |
| 248 IPC_STRUCT_MEMBER(bool, hidden) | 256 IPC_STRUCT_MEMBER(bool, hidden) |
| 249 IPC_STRUCT_END() | 257 IPC_STRUCT_END() |
| 250 | 258 |
| 251 IPC_STRUCT_BEGIN(FrameMsg_Navigate_Params) | 259 IPC_STRUCT_BEGIN(FrameMsg_Navigate_Params) |
| 252 // TODO(clamy): investigate which parameters are also needed in PlzNavigate | 260 // TODO(clamy): investigate which parameters are also needed in PlzNavigate |
| 253 // and move them to the appropriate NavigationParams struct. | 261 // and move them to the appropriate NavigationParams struct. |
| 254 | 262 |
| 255 // These structs contain parameters shared by other navigation IPCs. | 263 // These structs contain parameters shared by other navigation IPCs. |
| 256 IPC_STRUCT_MEMBER(content::CommonNavigationParams, common_params) | 264 IPC_STRUCT_MEMBER(content::CommonNavigationParams, common_params) |
| 257 IPC_STRUCT_MEMBER(content::CommitNavigationParams, commit_params) | 265 IPC_STRUCT_MEMBER(content::CommitNavigationParams, commit_params) |
| 266 IPC_STRUCT_MEMBER(content::HistoryNavigationParams, history_params) |
| 258 | 267 |
| 259 // Whether the navigation is a POST request (as opposed to a GET). | 268 // Whether the navigation is a POST request (as opposed to a GET). |
| 260 IPC_STRUCT_MEMBER(bool, is_post) | 269 IPC_STRUCT_MEMBER(bool, is_post) |
| 261 | 270 |
| 262 // Extra headers (separated by \n) to send during the request. | 271 // Extra headers (separated by \n) to send during the request. |
| 263 IPC_STRUCT_MEMBER(std::string, extra_headers) | 272 IPC_STRUCT_MEMBER(std::string, extra_headers) |
| 264 | 273 |
| 265 // If is_post is true, holds the post_data information from browser. Empty | 274 // If is_post is true, holds the post_data information from browser. Empty |
| 266 // otherwise. | 275 // otherwise. |
| 267 IPC_STRUCT_MEMBER(std::vector<unsigned char>, browser_initiated_post_data) | 276 IPC_STRUCT_MEMBER(std::vector<unsigned char>, browser_initiated_post_data) |
| 268 | 277 |
| 269 // The page_id for this navigation, or -1 if it is a new navigation. Back, | |
| 270 // Forward, and Reload navigations should have a valid page_id. If the load | |
| 271 // succeeds, then this page_id will be reflected in the resultant | |
| 272 // FrameHostMsg_DidCommitProvisionalLoad message. | |
| 273 IPC_STRUCT_MEMBER(int32, page_id) | |
| 274 | |
| 275 // For history navigations, this is the offset in the history list of the | |
| 276 // pending load. For non-history navigations, this will be ignored. | |
| 277 IPC_STRUCT_MEMBER(int, pending_history_list_offset) | |
| 278 | |
| 279 // Informs the RenderView of where its current page contents reside in | |
| 280 // session history and the total size of the session history list. | |
| 281 IPC_STRUCT_MEMBER(int, current_history_list_offset) | |
| 282 IPC_STRUCT_MEMBER(int, current_history_list_length) | |
| 283 | |
| 284 // Informs the RenderView the session history should be cleared. In that | |
| 285 // case, the RenderView needs to notify the browser that the clearing was | |
| 286 // succesful when the navigation commits. | |
| 287 IPC_STRUCT_MEMBER(bool, should_clear_history_list) | |
| 288 | |
| 289 // Any redirect URLs that occurred before |url|. Useful for cross-process | 278 // Any redirect URLs that occurred before |url|. Useful for cross-process |
| 290 // navigations; defaults to empty. | 279 // navigations; defaults to empty. |
| 291 IPC_STRUCT_MEMBER(std::vector<GURL>, redirects) | 280 IPC_STRUCT_MEMBER(std::vector<GURL>, redirects) |
| 292 | 281 |
| 293 // Informs the RenderView the pending navigation should replace the current | 282 // Informs the RenderView the pending navigation should replace the current |
| 294 // history entry when it commits. This is used for cross-process redirects so | 283 // history entry when it commits. This is used for cross-process redirects so |
| 295 // the transferred navigation can recover the navigation state. | 284 // the transferred navigation can recover the navigation state. |
| 296 IPC_STRUCT_MEMBER(bool, should_replace_current_entry) | 285 IPC_STRUCT_MEMBER(bool, should_replace_current_entry) |
| 297 | 286 |
| 298 // The time the request was created. This is used by the old performance | 287 // The time the request was created. This is used by the old performance |
| (...skipping 231 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 530 // External popup menus. | 519 // External popup menus. |
| 531 IPC_MESSAGE_ROUTED1(FrameMsg_SelectPopupMenuItem, | 520 IPC_MESSAGE_ROUTED1(FrameMsg_SelectPopupMenuItem, |
| 532 int /* selected index, -1 means no selection */) | 521 int /* selected index, -1 means no selection */) |
| 533 | 522 |
| 534 #endif | 523 #endif |
| 535 | 524 |
| 536 // PlzNavigate | 525 // PlzNavigate |
| 537 // Tells the renderer that a navigation is ready to commit. The renderer should | 526 // Tells the renderer that a navigation is ready to commit. The renderer should |
| 538 // request |stream_url| to get access to the stream containing the body of the | 527 // request |stream_url| to get access to the stream containing the body of the |
| 539 // response. | 528 // response. |
| 540 IPC_MESSAGE_ROUTED4(FrameMsg_CommitNavigation, | 529 IPC_MESSAGE_ROUTED5(FrameMsg_CommitNavigation, |
| 541 content::ResourceResponseHead, /* response */ | 530 content::ResourceResponseHead, /* response */ |
| 542 GURL, /* stream_url */ | 531 GURL, /* stream_url */ |
| 543 content::CommonNavigationParams, /* common_params */ | 532 content::CommonNavigationParams, /* common_params */ |
| 544 content::CommitNavigationParams /* commit_params */) | 533 content::CommitNavigationParams, /* commit_params */ |
| 534 content::HistoryNavigationParams /* history_params */) |
| 545 | 535 |
| 546 #if defined(ENABLE_PLUGINS) | 536 #if defined(ENABLE_PLUGINS) |
| 547 // Notifies the renderer of updates to the Plugin Power Saver origin whitelist. | 537 // Notifies the renderer of updates to the Plugin Power Saver origin whitelist. |
| 548 IPC_MESSAGE_ROUTED1(FrameMsg_UpdatePluginContentOriginWhitelist, | 538 IPC_MESSAGE_ROUTED1(FrameMsg_UpdatePluginContentOriginWhitelist, |
| 549 std::set<GURL> /* origin_whitelist */) | 539 std::set<GURL> /* origin_whitelist */) |
| 550 #endif // defined(ENABLE_PLUGINS) | 540 #endif // defined(ENABLE_PLUGINS) |
| 551 | 541 |
| 552 // ----------------------------------------------------------------------------- | 542 // ----------------------------------------------------------------------------- |
| 553 // Messages sent from the renderer to the browser. | 543 // Messages sent from the renderer to the browser. |
| 554 | 544 |
| (...skipping 308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 863 IPC_MESSAGE_ROUTED0(FrameHostMsg_DispatchLoad) | 853 IPC_MESSAGE_ROUTED0(FrameHostMsg_DispatchLoad) |
| 864 | 854 |
| 865 #if defined(OS_MACOSX) || defined(OS_ANDROID) | 855 #if defined(OS_MACOSX) || defined(OS_ANDROID) |
| 866 | 856 |
| 867 // Message to show/hide a popup menu using native controls. | 857 // Message to show/hide a popup menu using native controls. |
| 868 IPC_MESSAGE_ROUTED1(FrameHostMsg_ShowPopup, | 858 IPC_MESSAGE_ROUTED1(FrameHostMsg_ShowPopup, |
| 869 FrameHostMsg_ShowPopup_Params) | 859 FrameHostMsg_ShowPopup_Params) |
| 870 IPC_MESSAGE_ROUTED0(FrameHostMsg_HidePopup) | 860 IPC_MESSAGE_ROUTED0(FrameHostMsg_HidePopup) |
| 871 | 861 |
| 872 #endif | 862 #endif |
| OLD | NEW |