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
3 // found in the LICENSE file.
5 // Multiply-included file, no traditional include guard.
12 #include "base/files/file_path.h"
13 #include "base/memory/shared_memory.h"
14 #include "base/process/process.h"
15 #include "base/strings/string16.h"
16 #include "base/strings/stringprintf.h"
17 #include "base/values.h"
18 #include "build/build_config.h"
19 #include "chrome/common/common_param_traits.h"
20 #include "chrome/common/instant_types.h"
21 #include "chrome/common/ntp_logging_events.h"
22 #include "chrome/common/omnibox_focus_state.h"
23 #include "chrome/common/search_provider.h"
24 #include "chrome/common/web_application_info.h"
25 #include "components/content_settings/core/common/content_settings.h"
26 #include "components/content_settings/core/common/content_settings_pattern.h"
27 #include "components/content_settings/core/common/content_settings_types.h"
28 #include "components/nacl/common/nacl_types.h"
29 #include "content/public/common/common_param_traits.h"
30 #include "content/public/common/referrer.h"
31 #include "content/public/common/top_controls_state.h"
32 #include "ipc/ipc_channel_handle.h"
33 #include "ipc/ipc_message_macros.h"
34 #include "ipc/ipc_platform_file.h"
35 #include "third_party/WebKit/public/web/WebCache.h"
36 #include "third_party/WebKit/public/web/WebConsoleMessage.h"
37 #include "third_party/skia/include/core/SkBitmap.h"
38 #include "ui/base/window_open_disposition.h"
39 #include "ui/gfx/ipc/gfx_param_traits.h"
40 #include "ui/gfx/rect.h"
42 // Singly-included section for enums and custom IPC traits.
43 #ifndef CHROME_COMMON_RENDER_MESSAGES_H_
44 #define CHROME_COMMON_RENDER_MESSAGES_H_
46 // This enum is inside a struct so that we can forward-declare the struct in
47 // others headers without having to include this one.
48 struct ChromeViewHostMsg_GetPluginInfo_Status {
62 ChromeViewHostMsg_GetPluginInfo_Status() : value(kAllowed) {}
70 struct ParamTraits<ContentSettingsPattern> {
71 typedef ContentSettingsPattern param_type;
72 static void Write(Message* m, const param_type& p);
73 static bool Read(const Message* m, PickleIterator* iter, param_type* r);
74 static void Log(const param_type& p, std::string* l);
79 #endif // CHROME_COMMON_RENDER_MESSAGES_H_
81 #define IPC_MESSAGE_START ChromeMsgStart
83 IPC_ENUM_TRAITS_MAX_VALUE(ChromeViewHostMsg_GetPluginInfo_Status::Value,
84 ChromeViewHostMsg_GetPluginInfo_Status::kUnauthorized)
85 IPC_ENUM_TRAITS_MAX_VALUE(OmniboxFocusChangeReason,
86 OMNIBOX_FOCUS_CHANGE_REASON_LAST)
87 IPC_ENUM_TRAITS_MAX_VALUE(OmniboxFocusState, OMNIBOX_FOCUS_STATE_LAST)
88 IPC_ENUM_TRAITS_MAX_VALUE(search_provider::OSDDType,
89 search_provider::OSDD_TYPE_LAST)
90 IPC_ENUM_TRAITS(search_provider::InstallState)
91 IPC_ENUM_TRAITS(ThemeBackgroundImageAlignment)
92 IPC_ENUM_TRAITS(ThemeBackgroundImageTiling)
93 IPC_ENUM_TRAITS(blink::WebConsoleMessage::Level)
94 IPC_ENUM_TRAITS(content::TopControlsState)
96 IPC_STRUCT_TRAITS_BEGIN(ChromeViewHostMsg_GetPluginInfo_Status)
97 IPC_STRUCT_TRAITS_MEMBER(value)
98 IPC_STRUCT_TRAITS_END()
100 // Output parameters for ChromeViewHostMsg_GetPluginInfo message.
101 IPC_STRUCT_BEGIN(ChromeViewHostMsg_GetPluginInfo_Output)
102 IPC_STRUCT_MEMBER(ChromeViewHostMsg_GetPluginInfo_Status, status)
103 IPC_STRUCT_MEMBER(content::WebPluginInfo, plugin)
104 IPC_STRUCT_MEMBER(std::string, actual_mime_type)
105 IPC_STRUCT_MEMBER(std::string, group_identifier)
106 IPC_STRUCT_MEMBER(base::string16, group_name)
109 IPC_STRUCT_TRAITS_BEGIN(ContentSettingsPattern::PatternParts)
110 IPC_STRUCT_TRAITS_MEMBER(scheme)
111 IPC_STRUCT_TRAITS_MEMBER(is_scheme_wildcard)
112 IPC_STRUCT_TRAITS_MEMBER(host)
113 IPC_STRUCT_TRAITS_MEMBER(has_domain_wildcard)
114 IPC_STRUCT_TRAITS_MEMBER(port)
115 IPC_STRUCT_TRAITS_MEMBER(is_port_wildcard)
116 IPC_STRUCT_TRAITS_MEMBER(path)
117 IPC_STRUCT_TRAITS_MEMBER(is_path_wildcard)
118 IPC_STRUCT_TRAITS_END()
120 IPC_STRUCT_TRAITS_BEGIN(ContentSettingPatternSource)
121 IPC_STRUCT_TRAITS_MEMBER(primary_pattern)
122 IPC_STRUCT_TRAITS_MEMBER(secondary_pattern)
123 IPC_STRUCT_TRAITS_MEMBER(setting)
124 IPC_STRUCT_TRAITS_MEMBER(source)
125 IPC_STRUCT_TRAITS_MEMBER(incognito)
126 IPC_STRUCT_TRAITS_END()
128 IPC_STRUCT_TRAITS_BEGIN(EmbeddedSearchRequestParams)
129 IPC_STRUCT_TRAITS_MEMBER(search_query)
130 IPC_STRUCT_TRAITS_MEMBER(original_query)
131 IPC_STRUCT_TRAITS_MEMBER(rlz_parameter_value)
132 IPC_STRUCT_TRAITS_MEMBER(input_encoding)
133 IPC_STRUCT_TRAITS_MEMBER(assisted_query_stats)
134 IPC_STRUCT_TRAITS_END()
136 IPC_STRUCT_TRAITS_BEGIN(InstantSuggestion)
137 IPC_STRUCT_TRAITS_MEMBER(text)
138 IPC_STRUCT_TRAITS_MEMBER(metadata)
139 IPC_STRUCT_TRAITS_END()
141 IPC_STRUCT_TRAITS_BEGIN(InstantMostVisitedItem)
142 IPC_STRUCT_TRAITS_MEMBER(url)
143 IPC_STRUCT_TRAITS_MEMBER(title)
144 IPC_STRUCT_TRAITS_END()
146 IPC_STRUCT_TRAITS_BEGIN(RendererContentSettingRules)
147 IPC_STRUCT_TRAITS_MEMBER(image_rules)
148 IPC_STRUCT_TRAITS_MEMBER(script_rules)
149 IPC_STRUCT_TRAITS_END()
151 IPC_STRUCT_TRAITS_BEGIN(RGBAColor)
152 IPC_STRUCT_TRAITS_MEMBER(r)
153 IPC_STRUCT_TRAITS_MEMBER(g)
154 IPC_STRUCT_TRAITS_MEMBER(b)
155 IPC_STRUCT_TRAITS_MEMBER(a)
156 IPC_STRUCT_TRAITS_END()
158 IPC_STRUCT_TRAITS_BEGIN(ThemeBackgroundInfo)
159 IPC_STRUCT_TRAITS_MEMBER(using_default_theme)
160 IPC_STRUCT_TRAITS_MEMBER(background_color)
161 IPC_STRUCT_TRAITS_MEMBER(text_color)
162 IPC_STRUCT_TRAITS_MEMBER(link_color)
163 IPC_STRUCT_TRAITS_MEMBER(text_color_light)
164 IPC_STRUCT_TRAITS_MEMBER(header_color)
165 IPC_STRUCT_TRAITS_MEMBER(section_border_color)
166 IPC_STRUCT_TRAITS_MEMBER(theme_id)
167 IPC_STRUCT_TRAITS_MEMBER(image_horizontal_alignment)
168 IPC_STRUCT_TRAITS_MEMBER(image_vertical_alignment)
169 IPC_STRUCT_TRAITS_MEMBER(image_tiling)
170 IPC_STRUCT_TRAITS_MEMBER(image_height)
171 IPC_STRUCT_TRAITS_MEMBER(has_attribution)
172 IPC_STRUCT_TRAITS_MEMBER(logo_alternate)
173 IPC_STRUCT_TRAITS_END()
175 IPC_STRUCT_TRAITS_BEGIN(blink::WebCache::ResourceTypeStat)
176 IPC_STRUCT_TRAITS_MEMBER(count)
177 IPC_STRUCT_TRAITS_MEMBER(size)
178 IPC_STRUCT_TRAITS_MEMBER(liveSize)
179 IPC_STRUCT_TRAITS_MEMBER(decodedSize)
180 IPC_STRUCT_TRAITS_END()
182 IPC_STRUCT_TRAITS_BEGIN(blink::WebCache::ResourceTypeStats)
183 IPC_STRUCT_TRAITS_MEMBER(images)
184 IPC_STRUCT_TRAITS_MEMBER(cssStyleSheets)
185 IPC_STRUCT_TRAITS_MEMBER(scripts)
186 IPC_STRUCT_TRAITS_MEMBER(xslStyleSheets)
187 IPC_STRUCT_TRAITS_MEMBER(fonts)
188 IPC_STRUCT_TRAITS_END()
190 IPC_STRUCT_TRAITS_BEGIN(blink::WebCache::UsageStats)
191 IPC_STRUCT_TRAITS_MEMBER(minDeadCapacity)
192 IPC_STRUCT_TRAITS_MEMBER(maxDeadCapacity)
193 IPC_STRUCT_TRAITS_MEMBER(capacity)
194 IPC_STRUCT_TRAITS_MEMBER(liveSize)
195 IPC_STRUCT_TRAITS_MEMBER(deadSize)
196 IPC_STRUCT_TRAITS_END()
198 IPC_ENUM_TRAITS_MAX_VALUE(NTPLoggingEventType,
201 IPC_ENUM_TRAITS_MAX_VALUE(WebApplicationInfo::MobileCapable,
202 WebApplicationInfo::MOBILE_CAPABLE_APPLE)
204 IPC_STRUCT_TRAITS_BEGIN(WebApplicationInfo::IconInfo)
205 IPC_STRUCT_TRAITS_MEMBER(url)
206 IPC_STRUCT_TRAITS_MEMBER(width)
207 IPC_STRUCT_TRAITS_MEMBER(height)
208 IPC_STRUCT_TRAITS_MEMBER(data)
209 IPC_STRUCT_TRAITS_END()
211 IPC_STRUCT_TRAITS_BEGIN(WebApplicationInfo)
212 IPC_STRUCT_TRAITS_MEMBER(title)
213 IPC_STRUCT_TRAITS_MEMBER(description)
214 IPC_STRUCT_TRAITS_MEMBER(app_url)
215 IPC_STRUCT_TRAITS_MEMBER(icons)
216 IPC_STRUCT_TRAITS_MEMBER(mobile_capable)
217 IPC_STRUCT_TRAITS_END()
219 //-----------------------------------------------------------------------------
220 // RenderView messages
221 // These are messages sent from the browser to the renderer process.
223 #if !defined(OS_ANDROID) && !defined(OS_IOS)
224 // For WebUI testing, this message requests JavaScript to be executed at a time
225 // which is late enough to not be thrown out, and early enough to be before
226 // onload events are fired.
227 IPC_MESSAGE_ROUTED1(ChromeViewMsg_WebUIJavaScript,
228 base::string16 /* javascript */)
231 // Set the content setting rules stored by the renderer.
232 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetContentSettingRules,
233 RendererContentSettingRules /* rules */)
235 // Tells the render frame to load all blocked plugins with the given identifier.
236 IPC_MESSAGE_ROUTED1(ChromeViewMsg_LoadBlockedPlugins,
237 std::string /* identifier */)
239 // Asks the renderer to send back stats on the WebCore cache broken down by
241 IPC_MESSAGE_CONTROL0(ChromeViewMsg_GetCacheResourceStats)
243 // Tells the renderer to create a FieldTrial, and by using a 100% probability
244 // for the FieldTrial, forces the FieldTrial to have assigned group name.
245 IPC_MESSAGE_CONTROL2(ChromeViewMsg_SetFieldTrialGroup,
246 std::string /* field trial name */,
247 std::string /* group name that was assigned. */)
249 // Asks the renderer to send back V8 heap stats.
250 IPC_MESSAGE_CONTROL0(ChromeViewMsg_GetV8HeapStats)
252 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetPageSequenceNumber,
253 int /* page_seq_no */)
255 IPC_MESSAGE_ROUTED0(ChromeViewMsg_DetermineIfPageSupportsInstant)
257 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSetDisplayInstantResults,
258 bool /* display_instant_results */)
260 IPC_MESSAGE_ROUTED2(ChromeViewMsg_SearchBoxFocusChanged,
261 OmniboxFocusState /* new_focus_state */,
262 OmniboxFocusChangeReason /* reason */)
264 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxMarginChange, int /* start */)
266 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxMostVisitedItemsChanged,
267 std::vector<InstantMostVisitedItem> /* items */)
269 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxPromoInformation,
270 bool /* is_app_launcher_enabled */)
272 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSetInputInProgress,
273 bool /* input_in_progress */)
275 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSetSuggestionToPrefetch,
276 InstantSuggestion /* suggestion */)
278 IPC_MESSAGE_ROUTED2(ChromeViewMsg_SearchBoxSubmit,
279 base::string16 /* value */,
280 EmbeddedSearchRequestParams /* params */)
282 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxThemeChanged,
283 ThemeBackgroundInfo /* value */)
285 IPC_MESSAGE_ROUTED2(ChromeViewMsg_ChromeIdentityCheckResult,
286 base::string16 /* identity */,
287 bool /* identity_match */)
289 IPC_MESSAGE_ROUTED0(ChromeViewMsg_SearchBoxToggleVoiceSearch)
291 // Sent on process startup to indicate whether this process is running in
293 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetIsIncognitoProcess,
294 bool /* is_incognito_processs */)
296 // Sent in response to ViewHostMsg_DidBlockDisplayingInsecureContent.
297 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetAllowDisplayingInsecureContent,
300 // Sent in response to ViewHostMsg_DidBlockRunningInsecureContent.
301 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetAllowRunningInsecureContent,
304 IPC_MESSAGE_ROUTED0(ChromeViewMsg_ReloadFrame)
306 // Tells the renderer whether or not a file system access has been allowed.
307 IPC_MESSAGE_ROUTED2(ChromeViewMsg_RequestFileSystemAccessAsyncResponse,
308 int /* request_id */,
311 // Sent when the profile changes the kSafeBrowsingEnabled preference.
312 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetClientSidePhishingDetection,
313 bool /* enable_phishing_detection */)
315 // Asks the renderer for a thumbnail of the image selected by the most
316 // recently opened context menu, if there is one. If the image's area
317 // is greater than thumbnail_min_area it will be downscaled to
318 // be within thumbnail_max_size. The possibly downsampled image will be
319 // returned in a ChromeViewHostMsg_RequestThumbnailForContextNode_ACK message.
320 IPC_MESSAGE_ROUTED2(ChromeViewMsg_RequestThumbnailForContextNode,
321 int /* thumbnail_min_area_pixels */,
322 gfx::Size /* thumbnail_max_size_pixels */)
324 // Notifies the renderer whether hiding/showing the top controls is enabled,
325 // what the current state should be, and whether or not to animate to the
327 IPC_MESSAGE_ROUTED3(ChromeViewMsg_UpdateTopControlsState,
328 content::TopControlsState /* constraints */,
329 content::TopControlsState /* current */,
333 // Updates the window features of the render view.
334 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetWindowFeatures,
335 blink::WebWindowFeatures /* window_features */)
337 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_RequestThumbnailForContextNode_ACK,
338 SkBitmap /* thumbnail */,
339 gfx::Size /* original size of the image */)
341 // Requests application info for the page. The renderer responds back with
342 // ChromeViewHostMsg_DidGetWebApplicationInfo.
343 IPC_MESSAGE_ROUTED0(ChromeViewMsg_GetWebApplicationInfo)
345 #if defined(OS_ANDROID)
346 // Asks the renderer to return information about the given meta tag.
347 IPC_MESSAGE_ROUTED2(ChromeViewMsg_RetrieveMetaTagContent,
348 GURL /* expected_url */,
349 std::string /* tag_name */ )
350 #endif // defined(OS_ANDROID)
352 // chrome.principals messages ------------------------------------------------
354 // Message sent from the renderer to the browser to get the list of browser
355 // managed accounts for the given origin.
356 IPC_SYNC_MESSAGE_CONTROL1_1(ChromeViewHostMsg_GetManagedAccounts,
357 GURL /* current URL */,
358 std::vector<std::string> /* managed accounts */)
360 // Message sent from the renderer to the browser to show the browser account
362 IPC_MESSAGE_CONTROL0(ChromeViewHostMsg_ShowBrowserAccountManagementUI)
364 // JavaScript related messages -----------------------------------------------
366 // Tells the frame it is displaying an interstitial page.
367 IPC_MESSAGE_ROUTED0(ChromeViewMsg_SetAsInterstitial)
369 // Provides the renderer with the results of the browser's investigation into
370 // why a recent main frame load failed (currently, just DNS probe result).
371 // NetErrorHelper will receive this mesage and replace or update the error
372 // page with more specific troubleshooting suggestions.
373 IPC_MESSAGE_ROUTED1(ChromeViewMsg_NetErrorInfo,
374 int /* DNS probe status */)
376 // Provides the information needed by the renderer process to contact a
377 // navigation correction service. Handled by the NetErrorHelper.
378 IPC_MESSAGE_ROUTED5(ChromeViewMsg_SetNavigationCorrectionInfo,
379 GURL /* Navigation correction service base URL */,
380 std::string /* language */,
381 std::string /* origin_country */,
382 std::string /* API key to use */,
383 GURL /* Google Search URL to use */)
385 //-----------------------------------------------------------------------------
387 // These are messages sent from the renderer to the browser process.
389 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_UpdatedCacheStats,
390 blink::WebCache::UsageStats /* stats */)
392 // Tells the browser that content in the current page was blocked due to the
393 // user's content settings.
394 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_ContentBlocked,
395 ContentSettingsType /* type of blocked content */)
397 // Sent by the renderer process to check whether access to web databases is
398 // granted by content settings.
399 IPC_SYNC_MESSAGE_CONTROL5_1(ChromeViewHostMsg_AllowDatabase,
400 int /* render_frame_id */,
401 GURL /* origin_url */,
402 GURL /* top origin url */,
403 base::string16 /* database name */,
404 base::string16 /* database display name */,
407 // Sent by the renderer process to check whether access to DOM Storage is
408 // granted by content settings.
409 IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_AllowDOMStorage,
410 int /* render_frame_id */,
411 GURL /* origin_url */,
412 GURL /* top origin url */,
413 bool /* if true local storage, otherwise session */,
416 // Sent by the renderer process to check whether access to FileSystem is
417 // granted by content settings.
418 IPC_SYNC_MESSAGE_CONTROL3_1(ChromeViewHostMsg_RequestFileSystemAccessSync,
419 int /* render_frame_id */,
420 GURL /* origin_url */,
421 GURL /* top origin url */,
424 // Sent by the renderer process to check whether access to FileSystem is
425 // granted by content settings.
426 IPC_MESSAGE_CONTROL4(ChromeViewHostMsg_RequestFileSystemAccessAsync,
427 int /* render_frame_id */,
428 int /* request_id */,
429 GURL /* origin_url */,
430 GURL /* top origin url */)
432 // Sent by the renderer process to check whether access to Indexed DBis
433 // granted by content settings.
434 IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_AllowIndexedDB,
435 int /* render_frame_id */,
436 GURL /* origin_url */,
437 GURL /* top origin url */,
438 base::string16 /* database name */,
441 // Return information about a plugin for the given URL and MIME type.
442 // In contrast to ViewHostMsg_GetPluginInfo in content/, this IPC call knows
443 // about specific reasons why a plug-in can't be used, for example because it's
445 IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_GetPluginInfo,
446 int /* render_frame_id */,
448 GURL /* top origin url */,
449 std::string /* mime_type */,
450 ChromeViewHostMsg_GetPluginInfo_Output /* output */)
452 #if defined(ENABLE_PEPPER_CDMS)
453 // Returns whether any internal plugin supporting |mime_type| is registered and
454 // enabled. Does not determine whether the plugin can actually be instantiated
455 // (e.g. whether it has all its dependencies).
456 // When the returned *|is_available| is true, |additional_param_names| and
457 // |additional_param_values| contain the name-value pairs, if any, specified
458 // for the *first* non-disabled plugin found that is registered for |mime_type|.
459 IPC_SYNC_MESSAGE_CONTROL1_3(
460 ChromeViewHostMsg_IsInternalPluginAvailableForMimeType,
461 std::string /* mime_type */,
462 bool /* is_available */,
463 std::vector<base::string16> /* additional_param_names */,
464 std::vector<base::string16> /* additional_param_values */)
467 #if defined(ENABLE_PLUGIN_INSTALLATION)
468 // Tells the browser to search for a plug-in that can handle the given MIME
469 // type. The result will be sent asynchronously to the routing ID
471 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_FindMissingPlugin,
472 int /* placeholder_id */,
473 std::string /* mime_type */)
475 // Notifies the browser that a missing plug-in placeholder has been removed, so
476 // the corresponding PluginPlaceholderHost can be deleted.
477 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_RemovePluginPlaceholderHost,
478 int /* placeholder_id */)
480 // Notifies a missing plug-in placeholder that a plug-in with name |plugin_name|
482 IPC_MESSAGE_ROUTED1(ChromeViewMsg_FoundMissingPlugin,
483 base::string16 /* plugin_name */)
485 // Notifies a missing plug-in placeholder that no plug-in has been found.
486 IPC_MESSAGE_ROUTED0(ChromeViewMsg_DidNotFindMissingPlugin)
488 // Notifies a missing plug-in placeholder that we have started downloading
490 IPC_MESSAGE_ROUTED0(ChromeViewMsg_StartedDownloadingPlugin)
492 // Notifies a missing plug-in placeholder that we have finished downloading
494 IPC_MESSAGE_ROUTED0(ChromeViewMsg_FinishedDownloadingPlugin)
496 // Notifies a missing plug-in placeholder that there was an error downloading
498 IPC_MESSAGE_ROUTED1(ChromeViewMsg_ErrorDownloadingPlugin,
499 std::string /* message */)
500 #endif // defined(ENABLE_PLUGIN_INSTALLATION)
502 // Notifies a missing plug-in placeholder that the user cancelled downloading
504 IPC_MESSAGE_ROUTED0(ChromeViewMsg_CancelledDownloadingPlugin)
506 // Tells the browser to open chrome://plugins in a new tab. We use a separate
507 // message because renderer processes aren't allowed to directly navigate to
509 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_OpenAboutPlugins)
511 // Tells the browser that there was an error loading a plug-in.
512 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_CouldNotLoadPlugin,
513 base::FilePath /* plugin_path */)
515 // Tells the browser that we blocked a plug-in because NPAPI is not supported.
516 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_NPAPINotSupported,
517 std::string /* identifer */)
519 // Tells the renderer that the NPAPI cannot be used. For example Ash on windows.
520 IPC_MESSAGE_ROUTED0(ChromeViewMsg_NPAPINotSupported)
522 // Notification that the page has an OpenSearch description document
523 // associated with it.
524 IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_PageHasOSDD,
527 search_provider::OSDDType)
529 // Find out if the given url's security origin is installed as a search
531 IPC_SYNC_MESSAGE_ROUTED2_1(ChromeViewHostMsg_GetSearchProviderInstallState,
533 GURL /* inquiry url */,
534 search_provider::InstallState /* install */)
536 // Sends back stats about the V8 heap.
537 IPC_MESSAGE_CONTROL2(ChromeViewHostMsg_V8HeapStats,
538 int /* size of heap (allocated from the OS) */,
539 int /* bytes in use */)
541 // Request for a DNS prefetch of the names in the array.
542 // NameList is typedef'ed std::vector<std::string>
543 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_DnsPrefetch,
544 std::vector<std::string> /* hostnames */)
546 // Request for preconnect to host providing resource specified by URL
547 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_Preconnect,
548 GURL /* preconnect target url */)
550 // Notifies when a plugin couldn't be loaded because it's outdated.
551 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_BlockedOutdatedPlugin,
552 int /* placeholder ID */,
553 std::string /* plug-in group identifier */)
555 // Notifies when a plugin couldn't be loaded because it requires
556 // user authorization.
557 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_BlockedUnauthorizedPlugin,
558 base::string16 /* name */,
559 std::string /* plug-in group identifier */)
561 // Provide the browser process with information about the WebCore resource
562 // cache and current renderer framerate.
563 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_ResourceTypeStats,
564 blink::WebCache::ResourceTypeStats)
566 // Message sent from the renderer to the browser to notify it of a
567 // window.print() call which should cancel the prerender. The message is sent
568 // only when the renderer is prerendering.
569 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_CancelPrerenderForPrinting)
571 // Sent when the renderer was prevented from displaying insecure content in
572 // a secure page by a security policy. The page may appear incomplete.
573 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_DidBlockDisplayingInsecureContent)
575 // Sent when the renderer was prevented from running insecure content in
576 // a secure origin by a security policy. The page may appear incomplete.
577 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_DidBlockRunningInsecureContent)
579 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_DidGetWebApplicationInfo,
582 #if defined(OS_ANDROID)
583 IPC_MESSAGE_ROUTED4(ChromeViewHostMsg_DidRetrieveMetaTagContent,
585 std::string /* tag_name */,
586 std::string /* tag_content */,
587 GURL /* expected_url */)
588 #endif // defined(OS_ANDROID)
590 // Logs events from InstantExtended New Tab Pages.
591 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_LogEvent,
592 int /* page_seq_no */,
593 NTPLoggingEventType /* event */)
595 // Logs an impression on one of the Most Visited tile on the InstantExtended
597 IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_LogMostVisitedImpression,
598 int /* page_seq_no */,
600 base::string16 /* provider */)
602 // Logs a navigation on one of the Most Visited tile on the InstantExtended
604 IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_LogMostVisitedNavigation,
605 int /* page_seq_no */,
607 base::string16 /* provider */)
609 // The Instant page asks for Chrome identity check against |identity|.
610 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_ChromeIdentityCheck,
611 int /* page_seq_no */,
612 base::string16 /* identity */)
614 // Tells InstantExtended to set the omnibox focus state.
615 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_FocusOmnibox,
616 int /* page_seq_no */,
617 OmniboxFocusState /* state */)
619 // Tells InstantExtended to paste text into the omnibox. If text is empty,
620 // the clipboard contents will be pasted. This causes the omnibox dropdown to
622 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_PasteAndOpenDropdown,
623 int /* page_seq_no */,
624 base::string16 /* text to be pasted */)
626 // Tells InstantExtended whether the embedded search API is supported.
627 // See http://dev.chromium.org/embeddedsearch
628 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_InstantSupportDetermined,
629 int /* page_seq_no */,
632 // Tells InstantExtended to delete a most visited item.
633 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_SearchBoxDeleteMostVisitedItem,
634 int /* page_seq_no */,
637 // Tells InstantExtended to navigate the active tab to a possibly privileged
639 IPC_MESSAGE_ROUTED4(ChromeViewHostMsg_SearchBoxNavigate,
640 int /* page_seq_no */,
641 GURL /* destination */,
642 WindowOpenDisposition /* disposition */,
643 bool /*is_most_visited_item_url*/)
645 // Tells InstantExtended to undo all most visited item deletions.
646 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_SearchBoxUndoAllMostVisitedDeletions,
647 int /* page_seq_no */)
649 // Tells InstantExtended to undo one most visited item deletion.
650 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_SearchBoxUndoMostVisitedDeletion,
651 int /* page_seq_no */,
654 // Tells InstantExtended whether the page supports voice search.
655 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_SetVoiceSearchSupported,
656 int /* page_seq_no */,
657 bool /* supported */)
659 // Tells the renderer a list of URLs which should be bounced back to the browser
660 // process so that they can be assigned to an Instant renderer.
661 IPC_MESSAGE_CONTROL2(ChromeViewMsg_SetSearchURLs,
662 std::vector<GURL> /* search_urls */,
663 GURL /* new_tab_page_url */)
665 #if defined(ENABLE_PLUGINS)
666 // Sent by the renderer to check if crash reporting is enabled.
667 IPC_SYNC_MESSAGE_CONTROL0_1(ChromeViewHostMsg_IsCrashReportingEnabled,