Files.app: Stop to use file system URLs having externalfile:// scheme origin internally.
[chromium-blink-merge.git] / chrome / common / render_messages.h
blob550c29d31828cd2c442438ced18970d9aa9d2e61
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.
6 #include <stdint.h>
7 #include <map>
8 #include <set>
9 #include <string>
10 #include <vector>
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 {
49 enum Value {
50 kAllowed,
51 kBlocked,
52 kBlockedByPolicy,
53 kClickToPlay,
54 kDisabled,
55 kNotFound,
56 kNPAPINotSupported,
57 kOutdatedBlocked,
58 kOutdatedDisallowed,
59 kUnauthorized,
62 ChromeViewHostMsg_GetPluginInfo_Status() : value(kAllowed) {}
64 Value value;
67 namespace IPC {
69 template <>
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);
77 } // namespace IPC
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(OmniboxFocusChangeReason)
86 IPC_ENUM_TRAITS(OmniboxFocusState)
87 IPC_ENUM_TRAITS_MAX_VALUE(search_provider::OSDDType,
88 search_provider::OSDD_TYPE_LAST)
89 IPC_ENUM_TRAITS(search_provider::InstallState)
90 IPC_ENUM_TRAITS(ThemeBackgroundImageAlignment)
91 IPC_ENUM_TRAITS(ThemeBackgroundImageTiling)
92 IPC_ENUM_TRAITS(blink::WebConsoleMessage::Level)
93 IPC_ENUM_TRAITS(content::TopControlsState)
95 IPC_STRUCT_TRAITS_BEGIN(ChromeViewHostMsg_GetPluginInfo_Status)
96 IPC_STRUCT_TRAITS_MEMBER(value)
97 IPC_STRUCT_TRAITS_END()
99 // Output parameters for ChromeViewHostMsg_GetPluginInfo message.
100 IPC_STRUCT_BEGIN(ChromeViewHostMsg_GetPluginInfo_Output)
101 IPC_STRUCT_MEMBER(ChromeViewHostMsg_GetPluginInfo_Status, status)
102 IPC_STRUCT_MEMBER(content::WebPluginInfo, plugin)
103 IPC_STRUCT_MEMBER(std::string, actual_mime_type)
104 IPC_STRUCT_MEMBER(std::string, group_identifier)
105 IPC_STRUCT_MEMBER(base::string16, group_name)
106 IPC_STRUCT_END()
108 IPC_STRUCT_TRAITS_BEGIN(ContentSettingsPattern::PatternParts)
109 IPC_STRUCT_TRAITS_MEMBER(scheme)
110 IPC_STRUCT_TRAITS_MEMBER(is_scheme_wildcard)
111 IPC_STRUCT_TRAITS_MEMBER(host)
112 IPC_STRUCT_TRAITS_MEMBER(has_domain_wildcard)
113 IPC_STRUCT_TRAITS_MEMBER(port)
114 IPC_STRUCT_TRAITS_MEMBER(is_port_wildcard)
115 IPC_STRUCT_TRAITS_MEMBER(path)
116 IPC_STRUCT_TRAITS_MEMBER(is_path_wildcard)
117 IPC_STRUCT_TRAITS_END()
119 IPC_STRUCT_TRAITS_BEGIN(ContentSettingPatternSource)
120 IPC_STRUCT_TRAITS_MEMBER(primary_pattern)
121 IPC_STRUCT_TRAITS_MEMBER(secondary_pattern)
122 IPC_STRUCT_TRAITS_MEMBER(setting)
123 IPC_STRUCT_TRAITS_MEMBER(source)
124 IPC_STRUCT_TRAITS_MEMBER(incognito)
125 IPC_STRUCT_TRAITS_END()
127 IPC_STRUCT_TRAITS_BEGIN(InstantSuggestion)
128 IPC_STRUCT_TRAITS_MEMBER(text)
129 IPC_STRUCT_TRAITS_MEMBER(metadata)
130 IPC_STRUCT_TRAITS_END()
132 IPC_STRUCT_TRAITS_BEGIN(InstantMostVisitedItem)
133 IPC_STRUCT_TRAITS_MEMBER(url)
134 IPC_STRUCT_TRAITS_MEMBER(title)
135 IPC_STRUCT_TRAITS_END()
137 IPC_STRUCT_TRAITS_BEGIN(RendererContentSettingRules)
138 IPC_STRUCT_TRAITS_MEMBER(image_rules)
139 IPC_STRUCT_TRAITS_MEMBER(script_rules)
140 IPC_STRUCT_TRAITS_END()
142 IPC_STRUCT_TRAITS_BEGIN(RGBAColor)
143 IPC_STRUCT_TRAITS_MEMBER(r)
144 IPC_STRUCT_TRAITS_MEMBER(g)
145 IPC_STRUCT_TRAITS_MEMBER(b)
146 IPC_STRUCT_TRAITS_MEMBER(a)
147 IPC_STRUCT_TRAITS_END()
149 IPC_STRUCT_TRAITS_BEGIN(ThemeBackgroundInfo)
150 IPC_STRUCT_TRAITS_MEMBER(using_default_theme)
151 IPC_STRUCT_TRAITS_MEMBER(background_color)
152 IPC_STRUCT_TRAITS_MEMBER(text_color)
153 IPC_STRUCT_TRAITS_MEMBER(link_color)
154 IPC_STRUCT_TRAITS_MEMBER(text_color_light)
155 IPC_STRUCT_TRAITS_MEMBER(header_color)
156 IPC_STRUCT_TRAITS_MEMBER(section_border_color)
157 IPC_STRUCT_TRAITS_MEMBER(theme_id)
158 IPC_STRUCT_TRAITS_MEMBER(image_horizontal_alignment)
159 IPC_STRUCT_TRAITS_MEMBER(image_vertical_alignment)
160 IPC_STRUCT_TRAITS_MEMBER(image_tiling)
161 IPC_STRUCT_TRAITS_MEMBER(image_height)
162 IPC_STRUCT_TRAITS_MEMBER(has_attribution)
163 IPC_STRUCT_TRAITS_MEMBER(logo_alternate)
164 IPC_STRUCT_TRAITS_END()
166 IPC_STRUCT_TRAITS_BEGIN(blink::WebCache::ResourceTypeStat)
167 IPC_STRUCT_TRAITS_MEMBER(count)
168 IPC_STRUCT_TRAITS_MEMBER(size)
169 IPC_STRUCT_TRAITS_MEMBER(liveSize)
170 IPC_STRUCT_TRAITS_MEMBER(decodedSize)
171 IPC_STRUCT_TRAITS_END()
173 IPC_STRUCT_TRAITS_BEGIN(blink::WebCache::ResourceTypeStats)
174 IPC_STRUCT_TRAITS_MEMBER(images)
175 IPC_STRUCT_TRAITS_MEMBER(cssStyleSheets)
176 IPC_STRUCT_TRAITS_MEMBER(scripts)
177 IPC_STRUCT_TRAITS_MEMBER(xslStyleSheets)
178 IPC_STRUCT_TRAITS_MEMBER(fonts)
179 IPC_STRUCT_TRAITS_END()
181 IPC_STRUCT_TRAITS_BEGIN(blink::WebCache::UsageStats)
182 IPC_STRUCT_TRAITS_MEMBER(minDeadCapacity)
183 IPC_STRUCT_TRAITS_MEMBER(maxDeadCapacity)
184 IPC_STRUCT_TRAITS_MEMBER(capacity)
185 IPC_STRUCT_TRAITS_MEMBER(liveSize)
186 IPC_STRUCT_TRAITS_MEMBER(deadSize)
187 IPC_STRUCT_TRAITS_END()
189 IPC_ENUM_TRAITS_MAX_VALUE(NTPLoggingEventType,
190 NTP_NUM_EVENT_TYPES)
192 IPC_ENUM_TRAITS_MAX_VALUE(WebApplicationInfo::MobileCapable,
193 WebApplicationInfo::MOBILE_CAPABLE_APPLE)
195 IPC_STRUCT_TRAITS_BEGIN(WebApplicationInfo::IconInfo)
196 IPC_STRUCT_TRAITS_MEMBER(url)
197 IPC_STRUCT_TRAITS_MEMBER(width)
198 IPC_STRUCT_TRAITS_MEMBER(height)
199 IPC_STRUCT_TRAITS_MEMBER(data)
200 IPC_STRUCT_TRAITS_END()
202 IPC_STRUCT_TRAITS_BEGIN(WebApplicationInfo)
203 IPC_STRUCT_TRAITS_MEMBER(title)
204 IPC_STRUCT_TRAITS_MEMBER(description)
205 IPC_STRUCT_TRAITS_MEMBER(app_url)
206 IPC_STRUCT_TRAITS_MEMBER(icons)
207 IPC_STRUCT_TRAITS_MEMBER(mobile_capable)
208 IPC_STRUCT_TRAITS_END()
210 //-----------------------------------------------------------------------------
211 // RenderView messages
212 // These are messages sent from the browser to the renderer process.
214 #if !defined(OS_ANDROID) && !defined(OS_IOS)
215 // For WebUI testing, this message requests JavaScript to be executed at a time
216 // which is late enough to not be thrown out, and early enough to be before
217 // onload events are fired.
218 IPC_MESSAGE_ROUTED1(ChromeViewMsg_WebUIJavaScript,
219 base::string16 /* javascript */)
220 #endif
222 // Set the content setting rules stored by the renderer.
223 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetContentSettingRules,
224 RendererContentSettingRules /* rules */)
226 // Tells the render frame to load all blocked plugins with the given identifier.
227 IPC_MESSAGE_ROUTED1(ChromeViewMsg_LoadBlockedPlugins,
228 std::string /* identifier */)
230 // Asks the renderer to send back stats on the WebCore cache broken down by
231 // resource types.
232 IPC_MESSAGE_CONTROL0(ChromeViewMsg_GetCacheResourceStats)
234 // Tells the renderer to create a FieldTrial, and by using a 100% probability
235 // for the FieldTrial, forces the FieldTrial to have assigned group name.
236 IPC_MESSAGE_CONTROL2(ChromeViewMsg_SetFieldTrialGroup,
237 std::string /* field trial name */,
238 std::string /* group name that was assigned. */)
240 // Asks the renderer to send back V8 heap stats.
241 IPC_MESSAGE_CONTROL0(ChromeViewMsg_GetV8HeapStats)
243 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetPageSequenceNumber,
244 int /* page_seq_no */)
246 IPC_MESSAGE_ROUTED0(ChromeViewMsg_DetermineIfPageSupportsInstant)
248 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSetDisplayInstantResults,
249 bool /* display_instant_results */)
251 IPC_MESSAGE_ROUTED2(ChromeViewMsg_SearchBoxFocusChanged,
252 OmniboxFocusState /* new_focus_state */,
253 OmniboxFocusChangeReason /* reason */)
255 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxMarginChange, int /* start */)
257 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxMostVisitedItemsChanged,
258 std::vector<InstantMostVisitedItem> /* items */)
260 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxPromoInformation,
261 bool /* is_app_launcher_enabled */)
263 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSetInputInProgress,
264 bool /* input_in_progress */)
266 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSetSuggestionToPrefetch,
267 InstantSuggestion /* suggestion */)
269 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxSubmit,
270 base::string16 /* value */)
272 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SearchBoxThemeChanged,
273 ThemeBackgroundInfo /* value */)
275 IPC_MESSAGE_ROUTED2(ChromeViewMsg_ChromeIdentityCheckResult,
276 base::string16 /* identity */,
277 bool /* identity_match */)
279 IPC_MESSAGE_ROUTED0(ChromeViewMsg_SearchBoxToggleVoiceSearch)
281 // Sent on process startup to indicate whether this process is running in
282 // incognito mode.
283 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetIsIncognitoProcess,
284 bool /* is_incognito_processs */)
286 // Sent in response to ViewHostMsg_DidBlockDisplayingInsecureContent.
287 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetAllowDisplayingInsecureContent,
288 bool /* allowed */)
290 // Sent in response to ViewHostMsg_DidBlockRunningInsecureContent.
291 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetAllowRunningInsecureContent,
292 bool /* allowed */)
294 IPC_MESSAGE_ROUTED0(ChromeViewMsg_ReloadFrame)
296 // Tells the renderer whether or not a file system access has been allowed.
297 IPC_MESSAGE_ROUTED2(ChromeViewMsg_RequestFileSystemAccessAsyncResponse,
298 int /* request_id */,
299 bool /* allowed */)
301 // Sent when the profile changes the kSafeBrowsingEnabled preference.
302 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetClientSidePhishingDetection,
303 bool /* enable_phishing_detection */)
305 // Asks the renderer for a thumbnail of the image selected by the most
306 // recently opened context menu, if there is one. If the image's area
307 // is greater than thumbnail_min_area it will be downscaled to
308 // be within thumbnail_max_size. The possibly downsampled image will be
309 // returned in a ChromeViewHostMsg_RequestThumbnailForContextNode_ACK message.
310 IPC_MESSAGE_ROUTED2(ChromeViewMsg_RequestThumbnailForContextNode,
311 int /* thumbnail_min_area_pixels */,
312 gfx::Size /* thumbnail_max_size_pixels */)
314 // Notifies the renderer whether hiding/showing the top controls is enabled,
315 // what the current state should be, and whether or not to animate to the
316 // proper state.
317 IPC_MESSAGE_ROUTED3(ChromeViewMsg_UpdateTopControlsState,
318 content::TopControlsState /* constraints */,
319 content::TopControlsState /* current */,
320 bool /* animate */)
323 // Updates the window features of the render view.
324 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetWindowFeatures,
325 blink::WebWindowFeatures /* window_features */)
327 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_RequestThumbnailForContextNode_ACK,
328 SkBitmap /* thumbnail */,
329 gfx::Size /* original size of the image */)
331 // Requests application info for the page. The renderer responds back with
332 // ChromeViewHostMsg_DidGetWebApplicationInfo.
333 IPC_MESSAGE_ROUTED0(ChromeViewMsg_GetWebApplicationInfo)
335 #if defined(OS_ANDROID)
336 // Asks the renderer to return information about the given meta tag.
337 IPC_MESSAGE_ROUTED2(ChromeViewMsg_RetrieveMetaTagContent,
338 GURL /* expected_url */,
339 std::string /* tag_name */ )
340 #endif // defined(OS_ANDROID)
342 // chrome.principals messages ------------------------------------------------
344 // Message sent from the renderer to the browser to get the list of browser
345 // managed accounts for the given origin.
346 IPC_SYNC_MESSAGE_CONTROL1_1(ChromeViewHostMsg_GetManagedAccounts,
347 GURL /* current URL */,
348 std::vector<std::string> /* managed accounts */)
350 // Message sent from the renderer to the browser to show the browser account
351 // management UI.
352 IPC_MESSAGE_CONTROL0(ChromeViewHostMsg_ShowBrowserAccountManagementUI)
354 // JavaScript related messages -----------------------------------------------
356 // Tells the frame it is displaying an interstitial page.
357 IPC_MESSAGE_ROUTED0(ChromeViewMsg_SetAsInterstitial)
359 // Provides the renderer with the results of the browser's investigation into
360 // why a recent main frame load failed (currently, just DNS probe result).
361 // NetErrorHelper will receive this mesage and replace or update the error
362 // page with more specific troubleshooting suggestions.
363 IPC_MESSAGE_ROUTED1(ChromeViewMsg_NetErrorInfo,
364 int /* DNS probe status */)
366 // Provides the information needed by the renderer process to contact a
367 // navigation correction service. Handled by the NetErrorHelper.
368 IPC_MESSAGE_ROUTED5(ChromeViewMsg_SetNavigationCorrectionInfo,
369 GURL /* Navigation correction service base URL */,
370 std::string /* language */,
371 std::string /* origin_country */,
372 std::string /* API key to use */,
373 GURL /* Google Search URL to use */)
375 //-----------------------------------------------------------------------------
376 // Misc messages
377 // These are messages sent from the renderer to the browser process.
379 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_UpdatedCacheStats,
380 blink::WebCache::UsageStats /* stats */)
382 // Tells the browser that content in the current page was blocked due to the
383 // user's content settings.
384 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_ContentBlocked,
385 ContentSettingsType /* type of blocked content */)
387 // Sent by the renderer process to check whether access to web databases is
388 // granted by content settings.
389 IPC_SYNC_MESSAGE_CONTROL5_1(ChromeViewHostMsg_AllowDatabase,
390 int /* render_frame_id */,
391 GURL /* origin_url */,
392 GURL /* top origin url */,
393 base::string16 /* database name */,
394 base::string16 /* database display name */,
395 bool /* allowed */)
397 // Sent by the renderer process to check whether access to DOM Storage is
398 // granted by content settings.
399 IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_AllowDOMStorage,
400 int /* render_frame_id */,
401 GURL /* origin_url */,
402 GURL /* top origin url */,
403 bool /* if true local storage, otherwise session */,
404 bool /* allowed */)
406 // Sent by the renderer process to check whether access to FileSystem is
407 // granted by content settings.
408 IPC_SYNC_MESSAGE_CONTROL3_1(ChromeViewHostMsg_RequestFileSystemAccessSync,
409 int /* render_frame_id */,
410 GURL /* origin_url */,
411 GURL /* top origin url */,
412 bool /* allowed */)
414 // Sent by the renderer process to check whether access to FileSystem is
415 // granted by content settings.
416 IPC_MESSAGE_CONTROL4(ChromeViewHostMsg_RequestFileSystemAccessAsync,
417 int /* render_frame_id */,
418 int /* request_id */,
419 GURL /* origin_url */,
420 GURL /* top origin url */)
422 // Sent by the renderer process to check whether access to Indexed DBis
423 // granted by content settings.
424 IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_AllowIndexedDB,
425 int /* render_frame_id */,
426 GURL /* origin_url */,
427 GURL /* top origin url */,
428 base::string16 /* database name */,
429 bool /* allowed */)
431 // Return information about a plugin for the given URL and MIME type.
432 // In contrast to ViewHostMsg_GetPluginInfo in content/, this IPC call knows
433 // about specific reasons why a plug-in can't be used, for example because it's
434 // disabled.
435 IPC_SYNC_MESSAGE_CONTROL4_1(ChromeViewHostMsg_GetPluginInfo,
436 int /* render_frame_id */,
437 GURL /* url */,
438 GURL /* top origin url */,
439 std::string /* mime_type */,
440 ChromeViewHostMsg_GetPluginInfo_Output /* output */)
442 #if defined(ENABLE_PEPPER_CDMS)
443 // Returns whether any internal plugin supporting |mime_type| is registered and
444 // enabled. Does not determine whether the plugin can actually be instantiated
445 // (e.g. whether it has all its dependencies).
446 // When the returned *|is_available| is true, |additional_param_names| and
447 // |additional_param_values| contain the name-value pairs, if any, specified
448 // for the *first* non-disabled plugin found that is registered for |mime_type|.
449 IPC_SYNC_MESSAGE_CONTROL1_3(
450 ChromeViewHostMsg_IsInternalPluginAvailableForMimeType,
451 std::string /* mime_type */,
452 bool /* is_available */,
453 std::vector<base::string16> /* additional_param_names */,
454 std::vector<base::string16> /* additional_param_values */)
455 #endif
457 #if defined(ENABLE_PLUGIN_INSTALLATION)
458 // Tells the browser to search for a plug-in that can handle the given MIME
459 // type. The result will be sent asynchronously to the routing ID
460 // |placeholder_id|.
461 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_FindMissingPlugin,
462 int /* placeholder_id */,
463 std::string /* mime_type */)
465 // Notifies the browser that a missing plug-in placeholder has been removed, so
466 // the corresponding PluginPlaceholderHost can be deleted.
467 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_RemovePluginPlaceholderHost,
468 int /* placeholder_id */)
470 // Notifies a missing plug-in placeholder that a plug-in with name |plugin_name|
471 // has been found.
472 IPC_MESSAGE_ROUTED1(ChromeViewMsg_FoundMissingPlugin,
473 base::string16 /* plugin_name */)
475 // Notifies a missing plug-in placeholder that no plug-in has been found.
476 IPC_MESSAGE_ROUTED0(ChromeViewMsg_DidNotFindMissingPlugin)
478 // Notifies a missing plug-in placeholder that we have started downloading
479 // the plug-in.
480 IPC_MESSAGE_ROUTED0(ChromeViewMsg_StartedDownloadingPlugin)
482 // Notifies a missing plug-in placeholder that we have finished downloading
483 // the plug-in.
484 IPC_MESSAGE_ROUTED0(ChromeViewMsg_FinishedDownloadingPlugin)
486 // Notifies a missing plug-in placeholder that there was an error downloading
487 // the plug-in.
488 IPC_MESSAGE_ROUTED1(ChromeViewMsg_ErrorDownloadingPlugin,
489 std::string /* message */)
490 #endif // defined(ENABLE_PLUGIN_INSTALLATION)
492 // Notifies a missing plug-in placeholder that the user cancelled downloading
493 // the plug-in.
494 IPC_MESSAGE_ROUTED0(ChromeViewMsg_CancelledDownloadingPlugin)
496 // Tells the browser to open chrome://plugins in a new tab. We use a separate
497 // message because renderer processes aren't allowed to directly navigate to
498 // chrome:// URLs.
499 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_OpenAboutPlugins)
501 // Tells the browser that there was an error loading a plug-in.
502 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_CouldNotLoadPlugin,
503 base::FilePath /* plugin_path */)
505 // Tells the browser that we blocked a plug-in because NPAPI is not supported.
506 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_NPAPINotSupported,
507 std::string /* identifer */)
509 // Tells the renderer that the NPAPI cannot be used. For example Ash on windows.
510 IPC_MESSAGE_ROUTED0(ChromeViewMsg_NPAPINotSupported)
512 // Notification that the page has an OpenSearch description document
513 // associated with it.
514 IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_PageHasOSDD,
515 GURL /* page_url */,
516 GURL /* osdd_url */,
517 search_provider::OSDDType)
519 // Find out if the given url's security origin is installed as a search
520 // provider.
521 IPC_SYNC_MESSAGE_ROUTED2_1(ChromeViewHostMsg_GetSearchProviderInstallState,
522 GURL /* page url */,
523 GURL /* inquiry url */,
524 search_provider::InstallState /* install */)
526 // Sends back stats about the V8 heap.
527 IPC_MESSAGE_CONTROL2(ChromeViewHostMsg_V8HeapStats,
528 int /* size of heap (allocated from the OS) */,
529 int /* bytes in use */)
531 // Request for a DNS prefetch of the names in the array.
532 // NameList is typedef'ed std::vector<std::string>
533 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_DnsPrefetch,
534 std::vector<std::string> /* hostnames */)
536 // Request for preconnect to host providing resource specified by URL
537 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_Preconnect,
538 GURL /* preconnect target url */)
540 // Notifies when a plugin couldn't be loaded because it's outdated.
541 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_BlockedOutdatedPlugin,
542 int /* placeholder ID */,
543 std::string /* plug-in group identifier */)
545 // Notifies when a plugin couldn't be loaded because it requires
546 // user authorization.
547 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_BlockedUnauthorizedPlugin,
548 base::string16 /* name */,
549 std::string /* plug-in group identifier */)
551 // Provide the browser process with information about the WebCore resource
552 // cache and current renderer framerate.
553 IPC_MESSAGE_CONTROL1(ChromeViewHostMsg_ResourceTypeStats,
554 blink::WebCache::ResourceTypeStats)
556 // Message sent from the renderer to the browser to notify it of a
557 // window.print() call which should cancel the prerender. The message is sent
558 // only when the renderer is prerendering.
559 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_CancelPrerenderForPrinting)
561 // Sent when the renderer was prevented from displaying insecure content in
562 // a secure page by a security policy. The page may appear incomplete.
563 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_DidBlockDisplayingInsecureContent)
565 // Sent when the renderer was prevented from running insecure content in
566 // a secure origin by a security policy. The page may appear incomplete.
567 IPC_MESSAGE_ROUTED0(ChromeViewHostMsg_DidBlockRunningInsecureContent)
569 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_DidGetWebApplicationInfo,
570 WebApplicationInfo)
572 #if defined(OS_ANDROID)
573 IPC_MESSAGE_ROUTED4(ChromeViewHostMsg_DidRetrieveMetaTagContent,
574 bool /* success */,
575 std::string /* tag_name */,
576 std::string /* tag_content */,
577 GURL /* expected_url */)
578 #endif // defined(OS_ANDROID)
580 // Logs events from InstantExtended New Tab Pages.
581 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_LogEvent,
582 int /* page_seq_no */,
583 NTPLoggingEventType /* event */)
585 // Logs an impression on one of the Most Visited tile on the InstantExtended
586 // New Tab Page.
587 IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_LogMostVisitedImpression,
588 int /* page_seq_no */,
589 int /* position */,
590 base::string16 /* provider */)
592 // Logs a navigation on one of the Most Visited tile on the InstantExtended
593 // New Tab Page.
594 IPC_MESSAGE_ROUTED3(ChromeViewHostMsg_LogMostVisitedNavigation,
595 int /* page_seq_no */,
596 int /* position */,
597 base::string16 /* provider */)
599 // The Instant page asks for Chrome identity check against |identity|.
600 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_ChromeIdentityCheck,
601 int /* page_seq_no */,
602 base::string16 /* identity */)
604 // Tells InstantExtended to set the omnibox focus state.
605 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_FocusOmnibox,
606 int /* page_seq_no */,
607 OmniboxFocusState /* state */)
609 // Tells InstantExtended to paste text into the omnibox. If text is empty,
610 // the clipboard contents will be pasted. This causes the omnibox dropdown to
611 // open.
612 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_PasteAndOpenDropdown,
613 int /* page_seq_no */,
614 base::string16 /* text to be pasted */)
616 // Tells InstantExtended whether the embedded search API is supported.
617 // See http://dev.chromium.org/embeddedsearch
618 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_InstantSupportDetermined,
619 int /* page_seq_no */,
620 bool /* result */)
622 // Tells InstantExtended to delete a most visited item.
623 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_SearchBoxDeleteMostVisitedItem,
624 int /* page_seq_no */,
625 GURL /* url */)
627 // Tells InstantExtended to navigate the active tab to a possibly privileged
628 // URL.
629 IPC_MESSAGE_ROUTED4(ChromeViewHostMsg_SearchBoxNavigate,
630 int /* page_seq_no */,
631 GURL /* destination */,
632 WindowOpenDisposition /* disposition */,
633 bool /*is_most_visited_item_url*/)
635 // Tells InstantExtended to undo all most visited item deletions.
636 IPC_MESSAGE_ROUTED1(ChromeViewHostMsg_SearchBoxUndoAllMostVisitedDeletions,
637 int /* page_seq_no */)
639 // Tells InstantExtended to undo one most visited item deletion.
640 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_SearchBoxUndoMostVisitedDeletion,
641 int /* page_seq_no */,
642 GURL /* url */)
644 // Tells InstantExtended whether the page supports voice search.
645 IPC_MESSAGE_ROUTED2(ChromeViewHostMsg_SetVoiceSearchSupported,
646 int /* page_seq_no */,
647 bool /* supported */)
649 // Tells the renderer a list of URLs which should be bounced back to the browser
650 // process so that they can be assigned to an Instant renderer.
651 IPC_MESSAGE_CONTROL2(ChromeViewMsg_SetSearchURLs,
652 std::vector<GURL> /* search_urls */,
653 GURL /* new_tab_page_url */)
655 #if defined(ENABLE_PLUGINS)
656 // Sent by the renderer to check if crash reporting is enabled.
657 IPC_SYNC_MESSAGE_CONTROL0_1(ChromeViewHostMsg_IsCrashReportingEnabled,
658 bool /* enabled */)
659 #endif