Cast: Stop logging kVideoFrameSentToEncoder and rename a couple events.
[chromium-blink-merge.git] / content / common / frame_messages.h
blob38f4e199fdbe714e9adb5f0831631a0a267f3e6a
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
3 // found in the LICENSE file.
5 // IPC messages for interacting with frames.
6 // Multiply-included message file, hence no include guard.
8 #include "content/common/content_export.h"
9 #include "content/common/content_param_traits.h"
10 #include "content/common/frame_message_enums.h"
11 #include "content/common/frame_param.h"
12 #include "content/common/navigation_gesture.h"
13 #include "content/public/common/color_suggestion.h"
14 #include "content/public/common/common_param_traits.h"
15 #include "content/public/common/context_menu_params.h"
16 #include "content/public/common/frame_navigate_params.h"
17 #include "content/public/common/javascript_message_type.h"
18 #include "content/public/common/page_state.h"
19 #include "ipc/ipc_message_macros.h"
20 #include "url/gurl.h"
22 #undef IPC_MESSAGE_EXPORT
23 #define IPC_MESSAGE_EXPORT CONTENT_EXPORT
25 #define IPC_MESSAGE_START FrameMsgStart
27 IPC_ENUM_TRAITS_MIN_MAX_VALUE(content::JavaScriptMessageType,
28 content::JAVASCRIPT_MESSAGE_TYPE_ALERT,
29 content::JAVASCRIPT_MESSAGE_TYPE_PROMPT)
30 IPC_ENUM_TRAITS_MAX_VALUE(FrameMsg_Navigate_Type::Value,
31 FrameMsg_Navigate_Type::NAVIGATE_TYPE_LAST)
32 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebContextMenuData::MediaType,
33 blink::WebContextMenuData::MediaTypeLast)
34 IPC_ENUM_TRAITS_MAX_VALUE(ui::MenuSourceType, ui::MENU_SOURCE_TYPE_LAST)
36 IPC_STRUCT_TRAITS_BEGIN(content::ColorSuggestion)
37 IPC_STRUCT_TRAITS_MEMBER(color)
38 IPC_STRUCT_TRAITS_MEMBER(label)
39 IPC_STRUCT_TRAITS_END()
41 IPC_STRUCT_TRAITS_BEGIN(content::ContextMenuParams)
42 IPC_STRUCT_TRAITS_MEMBER(media_type)
43 IPC_STRUCT_TRAITS_MEMBER(x)
44 IPC_STRUCT_TRAITS_MEMBER(y)
45 IPC_STRUCT_TRAITS_MEMBER(link_url)
46 IPC_STRUCT_TRAITS_MEMBER(link_text)
47 IPC_STRUCT_TRAITS_MEMBER(unfiltered_link_url)
48 IPC_STRUCT_TRAITS_MEMBER(src_url)
49 IPC_STRUCT_TRAITS_MEMBER(has_image_contents)
50 IPC_STRUCT_TRAITS_MEMBER(page_url)
51 IPC_STRUCT_TRAITS_MEMBER(keyword_url)
52 IPC_STRUCT_TRAITS_MEMBER(frame_url)
53 IPC_STRUCT_TRAITS_MEMBER(frame_page_state)
54 IPC_STRUCT_TRAITS_MEMBER(media_flags)
55 IPC_STRUCT_TRAITS_MEMBER(selection_text)
56 IPC_STRUCT_TRAITS_MEMBER(misspelled_word)
57 IPC_STRUCT_TRAITS_MEMBER(misspelling_hash)
58 IPC_STRUCT_TRAITS_MEMBER(dictionary_suggestions)
59 IPC_STRUCT_TRAITS_MEMBER(spellcheck_enabled)
60 IPC_STRUCT_TRAITS_MEMBER(is_editable)
61 IPC_STRUCT_TRAITS_MEMBER(writing_direction_default)
62 IPC_STRUCT_TRAITS_MEMBER(writing_direction_left_to_right)
63 IPC_STRUCT_TRAITS_MEMBER(writing_direction_right_to_left)
64 IPC_STRUCT_TRAITS_MEMBER(edit_flags)
65 IPC_STRUCT_TRAITS_MEMBER(security_info)
66 IPC_STRUCT_TRAITS_MEMBER(frame_charset)
67 IPC_STRUCT_TRAITS_MEMBER(referrer_policy)
68 IPC_STRUCT_TRAITS_MEMBER(custom_context)
69 IPC_STRUCT_TRAITS_MEMBER(custom_items)
70 IPC_STRUCT_TRAITS_MEMBER(source_type)
71 #if defined(OS_ANDROID)
72 IPC_STRUCT_TRAITS_MEMBER(selection_start)
73 IPC_STRUCT_TRAITS_MEMBER(selection_end)
74 #endif
75 IPC_STRUCT_TRAITS_END()
77 IPC_STRUCT_TRAITS_BEGIN(content::CustomContextMenuContext)
78 IPC_STRUCT_TRAITS_MEMBER(is_pepper_menu)
79 IPC_STRUCT_TRAITS_MEMBER(request_id)
80 IPC_STRUCT_TRAITS_MEMBER(render_widget_id)
81 IPC_STRUCT_TRAITS_END()
83 IPC_STRUCT_BEGIN(FrameHostMsg_DidFailProvisionalLoadWithError_Params)
84 // The WebFrame's uniqueName().
85 IPC_STRUCT_MEMBER(base::string16, frame_unique_name)
86 // Error code as reported in the DidFailProvisionalLoad callback.
87 IPC_STRUCT_MEMBER(int, error_code)
88 // An error message generated from the error_code. This can be an empty
89 // string if we were unable to find a meaningful description.
90 IPC_STRUCT_MEMBER(base::string16, error_description)
91 // The URL that the error is reported for.
92 IPC_STRUCT_MEMBER(GURL, url)
93 // True if the failure is the result of navigating to a POST again
94 // and we're going to show the POST interstitial.
95 IPC_STRUCT_MEMBER(bool, showing_repost_interstitial)
96 IPC_STRUCT_END()
98 IPC_STRUCT_TRAITS_BEGIN(content::FrameNavigateParams)
99 IPC_STRUCT_TRAITS_MEMBER(page_id)
100 IPC_STRUCT_TRAITS_MEMBER(url)
101 IPC_STRUCT_TRAITS_MEMBER(base_url)
102 IPC_STRUCT_TRAITS_MEMBER(referrer)
103 IPC_STRUCT_TRAITS_MEMBER(transition)
104 IPC_STRUCT_TRAITS_MEMBER(redirects)
105 IPC_STRUCT_TRAITS_MEMBER(should_update_history)
106 IPC_STRUCT_TRAITS_MEMBER(searchable_form_url)
107 IPC_STRUCT_TRAITS_MEMBER(searchable_form_encoding)
108 IPC_STRUCT_TRAITS_MEMBER(contents_mime_type)
109 IPC_STRUCT_TRAITS_MEMBER(socket_address)
110 IPC_STRUCT_TRAITS_END()
112 // Parameters structure for FrameHostMsg_DidCommitProvisionalLoad, which has
113 // too many data parameters to be reasonably put in a predefined IPC message.
114 IPC_STRUCT_BEGIN_WITH_PARENT(FrameHostMsg_DidCommitProvisionalLoad_Params,
115 content::FrameNavigateParams)
116 IPC_STRUCT_TRAITS_PARENT(content::FrameNavigateParams)
117 // The WebFrame's uniqueName().
118 IPC_STRUCT_MEMBER(base::string16, frame_unique_name)
120 // Information regarding the security of the connection (empty if the
121 // connection was not secure).
122 IPC_STRUCT_MEMBER(std::string, security_info)
124 // The gesture that initiated this navigation.
125 IPC_STRUCT_MEMBER(content::NavigationGesture, gesture)
127 // True if this was a post request.
128 IPC_STRUCT_MEMBER(bool, is_post)
130 // The POST body identifier. -1 if it doesn't exist.
131 IPC_STRUCT_MEMBER(int64, post_id)
133 // Whether the frame navigation resulted in no change to the documents within
134 // the page. For example, the navigation may have just resulted in scrolling
135 // to a named anchor.
136 IPC_STRUCT_MEMBER(bool, was_within_same_page)
138 // The status code of the HTTP request.
139 IPC_STRUCT_MEMBER(int, http_status_code)
141 // True if the connection was proxied. In this case, socket_address
142 // will represent the address of the proxy, rather than the remote host.
143 IPC_STRUCT_MEMBER(bool, was_fetched_via_proxy)
145 // Serialized history item state to store in the navigation entry.
146 IPC_STRUCT_MEMBER(content::PageState, page_state)
148 // Original request's URL.
149 IPC_STRUCT_MEMBER(GURL, original_request_url)
151 // User agent override used to navigate.
152 IPC_STRUCT_MEMBER(bool, is_overriding_user_agent)
154 // Notifies the browser that for this navigation, the session history was
155 // successfully cleared.
156 IPC_STRUCT_MEMBER(bool, history_list_was_cleared)
157 IPC_STRUCT_END()
159 IPC_STRUCT_BEGIN(FrameMsg_Navigate_Params)
160 // The page_id for this navigation, or -1 if it is a new navigation. Back,
161 // Forward, and Reload navigations should have a valid page_id. If the load
162 // succeeds, then this page_id will be reflected in the resultant
163 // FrameHostMsg_DidCommitProvisionalLoad message.
164 IPC_STRUCT_MEMBER(int32, page_id)
166 // If page_id is -1, then pending_history_list_offset will also be -1.
167 // Otherwise, it contains the offset into the history list corresponding to
168 // the current navigation.
169 IPC_STRUCT_MEMBER(int, pending_history_list_offset)
171 // Informs the RenderView of where its current page contents reside in
172 // session history and the total size of the session history list.
173 IPC_STRUCT_MEMBER(int, current_history_list_offset)
174 IPC_STRUCT_MEMBER(int, current_history_list_length)
176 // Informs the RenderView the session history should be cleared. In that
177 // case, the RenderView needs to notify the browser that the clearing was
178 // succesful when the navigation commits.
179 IPC_STRUCT_MEMBER(bool, should_clear_history_list)
181 // The URL to load.
182 IPC_STRUCT_MEMBER(GURL, url)
184 // Base URL for use in WebKit's SubstituteData.
185 // Is only used with data: URLs.
186 IPC_STRUCT_MEMBER(GURL, base_url_for_data_url)
188 // History URL for use in WebKit's SubstituteData.
189 // Is only used with data: URLs.
190 IPC_STRUCT_MEMBER(GURL, history_url_for_data_url)
192 // The URL to send in the "Referer" header field. Can be empty if there is
193 // no referrer.
194 IPC_STRUCT_MEMBER(content::Referrer, referrer)
196 // Any redirect URLs that occurred before |url|. Useful for cross-process
197 // navigations; defaults to empty.
198 IPC_STRUCT_MEMBER(std::vector<GURL>, redirects)
200 // The type of transition.
201 IPC_STRUCT_MEMBER(content::PageTransition, transition)
203 // Informs the RenderView the pending navigation should replace the current
204 // history entry when it commits. This is used for cross-process redirects so
205 // the transferred navigation can recover the navigation state.
206 IPC_STRUCT_MEMBER(bool, should_replace_current_entry)
208 // Opaque history state (received by ViewHostMsg_UpdateState).
209 IPC_STRUCT_MEMBER(content::PageState, page_state)
211 // Type of navigation.
212 IPC_STRUCT_MEMBER(FrameMsg_Navigate_Type::Value, navigation_type)
214 // The time the request was created
215 IPC_STRUCT_MEMBER(base::Time, request_time)
217 // Extra headers (separated by \n) to send during the request.
218 IPC_STRUCT_MEMBER(std::string, extra_headers)
220 // The following two members identify a previous request that has been
221 // created before this navigation is being transferred to a new render view.
222 // This serves the purpose of recycling the old request.
223 // Unless this refers to a transferred navigation, these values are -1 and -1.
224 IPC_STRUCT_MEMBER(int, transferred_request_child_id)
225 IPC_STRUCT_MEMBER(int, transferred_request_request_id)
227 // Whether or not we should allow the url to download.
228 IPC_STRUCT_MEMBER(bool, allow_download)
230 // Whether or not the user agent override string should be used.
231 IPC_STRUCT_MEMBER(bool, is_overriding_user_agent)
233 // True if this was a post request.
234 IPC_STRUCT_MEMBER(bool, is_post)
236 // If is_post is true, holds the post_data information from browser. Empty
237 // otherwise.
238 IPC_STRUCT_MEMBER(std::vector<unsigned char>, browser_initiated_post_data)
240 // Whether or not this url should be allowed to access local file://
241 // resources.
242 IPC_STRUCT_MEMBER(bool, can_load_local_resources)
244 // If not empty, which frame to navigate.
245 IPC_STRUCT_MEMBER(std::string, frame_to_navigate)
247 // The navigationStart time to expose to JS for this navigation.
248 IPC_STRUCT_MEMBER(base::TimeTicks, browser_navigation_start)
249 IPC_STRUCT_END()
251 IPC_STRUCT_BEGIN(FrameHostMsg_OpenURL_Params)
252 IPC_STRUCT_MEMBER(GURL, url)
253 IPC_STRUCT_MEMBER(content::Referrer, referrer)
254 IPC_STRUCT_MEMBER(WindowOpenDisposition, disposition)
255 IPC_STRUCT_MEMBER(bool, should_replace_current_entry)
256 IPC_STRUCT_MEMBER(bool, user_gesture)
257 IPC_STRUCT_END()
259 // -----------------------------------------------------------------------------
260 // Messages sent from the browser to the renderer.
262 // When HW accelerated buffers are swapped in an out-of-process child frame
263 // renderer, the message is forwarded to the embedding frame to notify it of
264 // a new texture available for compositing. When the buffer has finished
265 // presenting, a FrameHostMsg_BuffersSwappedACK should be sent back to
266 // gpu host that produced this buffer.
268 // This is used in the non-ubercomp HW accelerated compositing path.
269 IPC_MESSAGE_ROUTED1(FrameMsg_BuffersSwapped,
270 FrameMsg_BuffersSwapped_Params /* params */)
272 // Notifies the embedding frame that a new CompositorFrame is ready to be
273 // presented. When the frame finishes presenting, a matching
274 // FrameHostMsg_CompositorFrameSwappedACK should be sent back to the
275 // RenderViewHost that was produced the CompositorFrame.
277 // This is used in the ubercomp compositing path.
278 IPC_MESSAGE_ROUTED1(FrameMsg_CompositorFrameSwapped,
279 FrameMsg_CompositorFrameSwapped_Params /* params */)
281 // Notifies the embedding frame that the process rendering the child frame's
282 // contents has terminated.
283 IPC_MESSAGE_ROUTED0(FrameMsg_ChildFrameProcessGone)
285 // Sent in response to a FrameHostMsg_ContextMenu to let the renderer know that
286 // the menu has been closed.
287 IPC_MESSAGE_ROUTED1(FrameMsg_ContextMenuClosed,
288 content::CustomContextMenuContext /* custom_context */)
290 // Executes custom context menu action that was provided from Blink.
291 IPC_MESSAGE_ROUTED2(FrameMsg_CustomContextMenuAction,
292 content::CustomContextMenuContext /* custom_context */,
293 unsigned /* action */)
295 // Tells the renderer to perform the specified navigation, interrupting any
296 // existing navigation.
297 IPC_MESSAGE_ROUTED1(FrameMsg_Navigate, FrameMsg_Navigate_Params)
299 // Instructs the renderer to invoke the frame's beforeunload event handler.
300 // Expects the result to be returned via FrameHostMsg_BeforeUnload_ACK.
301 IPC_MESSAGE_ROUTED0(FrameMsg_BeforeUnload)
303 // Instructs the frame to swap out for a cross-site transition, including
304 // running the unload event handler. Expects a SwapOut_ACK message when
305 // finished.
306 IPC_MESSAGE_ROUTED0(FrameMsg_SwapOut)
308 // Request for the renderer to insert CSS into the frame.
309 IPC_MESSAGE_ROUTED1(FrameMsg_CSSInsertRequest,
310 std::string /* css */)
312 // Request for the renderer to execute JavaScript in the frame's context.
314 // javascript is the string containing the JavaScript to be executed in the
315 // target frame's context.
317 // If the third parameter is true the result is sent back to the browser using
318 // the message FrameHostMsg_JavaScriptExecuteResponse.
319 // FrameHostMsg_JavaScriptExecuteResponse is passed the ID parameter so that the
320 // host can uniquely identify the request.
321 IPC_MESSAGE_ROUTED3(FrameMsg_JavaScriptExecuteRequest,
322 base::string16, /* javascript */
323 int, /* ID */
324 bool /* if true, a reply is requested */)
326 // Selects between the given start and end offsets in the currently focused
327 // editable field.
328 IPC_MESSAGE_ROUTED2(FrameMsg_SetEditableSelectionOffsets,
329 int /* start */,
330 int /* end */)
332 // Sets the text composition to be between the given start and end offsets in
333 // the currently focused editable field.
334 IPC_MESSAGE_ROUTED3(FrameMsg_SetCompositionFromExistingText,
335 int /* start */,
336 int /* end */,
337 std::vector<blink::WebCompositionUnderline> /* underlines */)
339 // Deletes the current selection plus the specified number of characters before
340 // and after the selection or caret.
341 IPC_MESSAGE_ROUTED2(FrameMsg_ExtendSelectionAndDelete,
342 int /* before */,
343 int /* after */)
345 // Tells the renderer to reload the frame, optionally ignoring the cache while
346 // doing so.
347 IPC_MESSAGE_ROUTED1(FrameMsg_Reload,
348 bool /* ignore_cache */)
350 // Notifies the color chooser client that the user selected a color.
351 IPC_MESSAGE_ROUTED2(FrameMsg_DidChooseColorResponse, unsigned, SkColor)
353 // Notifies the color chooser client that the color chooser has ended.
354 IPC_MESSAGE_ROUTED1(FrameMsg_DidEndColorChooser, unsigned)
356 // -----------------------------------------------------------------------------
357 // Messages sent from the renderer to the browser.
359 // Blink and JavaScript error messages to log to the console
360 // or debugger UI.
361 IPC_MESSAGE_ROUTED4(FrameHostMsg_AddMessageToConsole,
362 int32, /* log level */
363 base::string16, /* msg */
364 int32, /* line number */
365 base::string16 /* source id */ )
367 // Sent by the renderer when a child frame is created in the renderer.
369 // Each of these messages will have a corresponding FrameHostMsg_Detach message
370 // sent when the frame is detached from the DOM.
371 IPC_SYNC_MESSAGE_CONTROL2_1(FrameHostMsg_CreateChildFrame,
372 int32 /* parent_routing_id */,
373 std::string /* frame_name */,
374 int32 /* new_routing_id */)
376 // Sent by the renderer to the parent RenderFrameHost when a child frame is
377 // detached from the DOM.
378 IPC_MESSAGE_ROUTED0(FrameHostMsg_Detach)
380 // Sent by the renderer when the frame becomes focused.
381 IPC_MESSAGE_ROUTED0(FrameHostMsg_FrameFocused)
383 // Sent when the renderer starts a provisional load for a frame.
384 IPC_MESSAGE_ROUTED2(FrameHostMsg_DidStartProvisionalLoadForFrame,
385 int32 /* parent_routing_id */,
386 GURL /* url */)
388 // Sent when the renderer fails a provisional load with an error.
389 IPC_MESSAGE_ROUTED1(FrameHostMsg_DidFailProvisionalLoadWithError,
390 FrameHostMsg_DidFailProvisionalLoadWithError_Params)
392 // Sent when a provisional load on the main frame redirects.
393 IPC_MESSAGE_ROUTED3(FrameHostMsg_DidRedirectProvisionalLoad,
394 int /* page_id */,
395 GURL /* source_url*/,
396 GURL /* target_url */)
398 // Notifies the browser that a frame in the view has changed. This message
399 // has a lot of parameters and is packed/unpacked by functions defined in
400 // render_messages.h.
401 IPC_MESSAGE_ROUTED1(FrameHostMsg_DidCommitProvisionalLoad,
402 FrameHostMsg_DidCommitProvisionalLoad_Params)
404 // Notifies the browser that a document has been loaded.
405 IPC_MESSAGE_ROUTED0(FrameHostMsg_DidFinishDocumentLoad)
407 IPC_MESSAGE_ROUTED3(FrameHostMsg_DidFailLoadWithError,
408 GURL /* validated_url */,
409 int /* error_code */,
410 base::string16 /* error_description */)
412 // Sent when the renderer starts loading the page. This corresponds to
413 // Blink's notion of the throbber starting. Note that sometimes you may get
414 // duplicates of these during a single load.
415 // |to_different_document| will be true unless the load is a fragment
416 // navigation, or triggered by history.pushState/replaceState.
417 IPC_MESSAGE_ROUTED1(FrameHostMsg_DidStartLoading,
418 bool /* to_different_document */)
420 // Sent when the renderer is done loading a page. This corresponds to Blink's
421 // notion of the throbber stopping.
422 IPC_MESSAGE_ROUTED0(FrameHostMsg_DidStopLoading)
424 // Requests that the given URL be opened in the specified manner.
425 IPC_MESSAGE_ROUTED1(FrameHostMsg_OpenURL, FrameHostMsg_OpenURL_Params)
427 // Notifies the browser that a frame finished loading.
428 IPC_MESSAGE_ROUTED1(FrameHostMsg_DidFinishLoad,
429 GURL /* validated_url */)
431 // Sent when after the onload handler has been invoked for the document
432 // in this frame. Sent for top-level frames.
433 IPC_MESSAGE_ROUTED0(FrameHostMsg_DocumentOnLoadCompleted)
435 // Notifies that the initial empty document of a view has been accessed.
436 // After this, it is no longer safe to show a pending navigation's URL without
437 // making a URL spoof possible.
438 IPC_MESSAGE_ROUTED0(FrameHostMsg_DidAccessInitialDocument)
440 // Sent when the frame sets its opener to null, disowning it for the lifetime of
441 // the window. Sent for top-level frames.
442 IPC_MESSAGE_ROUTED0(FrameHostMsg_DidDisownOpener)
444 // Following message is used to communicate the values received by the
445 // callback binding the JS to Cpp.
446 // An instance of browser that has an automation host listening to it can
447 // have a javascript send a native value (string, number, boolean) to the
448 // listener in Cpp. (DomAutomationController)
449 IPC_MESSAGE_ROUTED2(FrameHostMsg_DomOperationResponse,
450 std::string /* json_string */,
451 int /* automation_id */)
453 // Sent to the browser when the renderer detects it is blocked on a pepper
454 // plugin message for too long. This is also sent when it becomes unhung
455 // (according to the value of is_hung). The browser can give the user the
456 // option of killing the plugin.
457 IPC_MESSAGE_ROUTED3(FrameHostMsg_PepperPluginHung,
458 int /* plugin_child_id */,
459 base::FilePath /* path */,
460 bool /* is_hung */)
462 // Sent by the renderer process to indicate that a plugin instance has crashed.
463 // Note: |plugin_pid| should not be trusted. The corresponding process has
464 // probably died. Moreover, the ID may have been reused by a new process. Any
465 // usage other than displaying it in a prompt to the user is very likely to be
466 // wrong.
467 IPC_MESSAGE_ROUTED2(FrameHostMsg_PluginCrashed,
468 base::FilePath /* plugin_path */,
469 base::ProcessId /* plugin_pid */)
471 // Return information about a plugin for the given URL and MIME
472 // type. If there is no matching plugin, |found| is false.
473 // |actual_mime_type| is the actual mime type supported by the
474 // found plugin.
475 IPC_SYNC_MESSAGE_CONTROL4_3(FrameHostMsg_GetPluginInfo,
476 int /* render_frame_id */,
477 GURL /* url */,
478 GURL /* page_url */,
479 std::string /* mime_type */,
480 bool /* found */,
481 content::WebPluginInfo /* plugin info */,
482 std::string /* actual_mime_type */)
484 // A renderer sends this to the browser process when it wants to
485 // create a plugin. The browser will create the plugin process if
486 // necessary, and will return a handle to the channel on success.
487 // On error an empty string is returned.
488 IPC_SYNC_MESSAGE_CONTROL4_2(FrameHostMsg_OpenChannelToPlugin,
489 int /* render_frame_id */,
490 GURL /* url */,
491 GURL /* page_url */,
492 std::string /* mime_type */,
493 IPC::ChannelHandle /* channel_handle */,
494 content::WebPluginInfo /* info */)
496 // Acknowledge that we presented a HW buffer and provide a sync point
497 // to specify the location in the command stream when the compositor
498 // is no longer using it.
500 // See FrameMsg_BuffersSwapped.
501 IPC_MESSAGE_ROUTED1(FrameHostMsg_BuffersSwappedACK,
502 FrameHostMsg_BuffersSwappedACK_Params /* params */)
504 // Acknowledge that we presented an ubercomp frame.
506 // See FrameMsg_CompositorFrameSwapped
507 IPC_MESSAGE_ROUTED1(FrameHostMsg_CompositorFrameSwappedACK,
508 FrameHostMsg_CompositorFrameSwappedACK_Params /* params */)
510 // Provides the result from handling BeforeUnload. |proceed| matches the return
511 // value of the frame's beforeunload handler: true if the user decided to
512 // proceed with leaving the page.
513 IPC_MESSAGE_ROUTED3(FrameHostMsg_BeforeUnload_ACK,
514 bool /* proceed */,
515 base::TimeTicks /* before_unload_start_time */,
516 base::TimeTicks /* before_unload_end_time */)
518 // Indicates that the current frame has swapped out, after a SwapOut message.
519 IPC_MESSAGE_ROUTED0(FrameHostMsg_SwapOut_ACK)
521 IPC_MESSAGE_ROUTED1(FrameHostMsg_ReclaimCompositorResources,
522 FrameHostMsg_ReclaimCompositorResources_Params /* params */)
524 // Forwards an input event to a child.
525 // TODO(nick): Temporary bridge, revisit once the browser process can route
526 // input directly to subframes. http://crbug.com/339659
527 IPC_MESSAGE_ROUTED1(FrameHostMsg_ForwardInputEvent,
528 IPC::WebInputEventPointer /* event */)
530 // Used to tell the parent that the user right clicked on an area of the
531 // content area, and a context menu should be shown for it. The params
532 // object contains information about the node(s) that were selected when the
533 // user right clicked.
534 IPC_MESSAGE_ROUTED1(FrameHostMsg_ContextMenu, content::ContextMenuParams)
536 // Initial drawing parameters for a child frame that has been swapped out to
537 // another process.
538 IPC_MESSAGE_ROUTED2(FrameHostMsg_InitializeChildFrame,
539 gfx::Rect /* frame_rect */,
540 float /* scale_factor */)
542 // Response for FrameMsg_JavaScriptExecuteRequest, sent when a reply was
543 // requested. The ID is the parameter supplied to
544 // FrameMsg_JavaScriptExecuteRequest. The result has the value returned by the
545 // script as its only element, one of Null, Boolean, Integer, Real, Date, or
546 // String.
547 IPC_MESSAGE_ROUTED2(FrameHostMsg_JavaScriptExecuteResponse,
548 int /* id */,
549 base::ListValue /* result */)
551 // A request to run a JavaScript dialog.
552 IPC_SYNC_MESSAGE_ROUTED4_2(FrameHostMsg_RunJavaScriptMessage,
553 base::string16 /* in - alert message */,
554 base::string16 /* in - default prompt */,
555 GURL /* in - originating page URL */,
556 content::JavaScriptMessageType /* in - type */,
557 bool /* out - success */,
558 base::string16 /* out - user_input field */)
560 // Displays a dialog to confirm that the user wants to navigate away from the
561 // page. Replies true if yes, and false otherwise. The reply string is ignored,
562 // but is included so that we can use OnJavaScriptMessageBoxClosed.
563 IPC_SYNC_MESSAGE_ROUTED3_2(FrameHostMsg_RunBeforeUnloadConfirm,
564 GURL, /* in - originating frame URL */
565 base::string16 /* in - alert message */,
566 bool /* in - is a reload */,
567 bool /* out - success */,
568 base::string16 /* out - This is ignored.*/)
570 // Asks the browser to open the color chooser.
571 IPC_MESSAGE_ROUTED3(FrameHostMsg_OpenColorChooser,
572 int /* id */,
573 SkColor /* color */,
574 std::vector<content::ColorSuggestion> /* suggestions */)
576 // Asks the browser to end the color chooser.
577 IPC_MESSAGE_ROUTED1(FrameHostMsg_EndColorChooser, int /* id */)
579 // Change the selected color in the color chooser.
580 IPC_MESSAGE_ROUTED2(FrameHostMsg_SetSelectedColorInColorChooser,
581 int /* id */,
582 SkColor /* color */)
584 // Notifies the browser that media has started/stopped playing.
585 IPC_MESSAGE_ROUTED3(FrameHostMsg_MediaPlayingNotification,
586 int64 /* player_cookie, distinguishes instances */,
587 bool /* has_video */,
588 bool /* has_audio */)
590 IPC_MESSAGE_ROUTED1(FrameHostMsg_MediaPausedNotification,
591 int64 /* player_cookie, distinguishes instances */)