OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 // Chrome-specific IPC messages for extensions. | 5 // Chrome-specific IPC messages for extensions. |
6 // Extension-related messages that aren't specific to Chrome live in | 6 // Extension-related messages that aren't specific to Chrome live in |
7 // extensions/common/extension_messages.h. | 7 // extensions/common/extension_messages.h. |
8 // | 8 // |
9 // Multiply-included message file, hence no include guard. | 9 // Multiply-included message file, hence no include guard. |
10 | 10 |
11 #include <string> | 11 #include <string> |
12 | 12 |
13 #include "base/strings/string16.h" | 13 #include "base/strings/string16.h" |
14 #include "base/values.h" | 14 #include "base/values.h" |
15 #include "chrome/common/extensions/api/webstore/webstore_api_constants.h" | 15 #include "chrome/common/extensions/api/webstore/webstore_api_constants.h" |
16 #include "chrome/common/extensions/webstore_install_result.h" | 16 #include "chrome/common/extensions/webstore_install_result.h" |
17 #include "chrome/common/web_application_info.h" | |
18 #include "extensions/common/stack_frame.h" | 17 #include "extensions/common/stack_frame.h" |
19 #include "ipc/ipc_message_macros.h" | 18 #include "ipc/ipc_message_macros.h" |
20 #include "url/gurl.h" | 19 #include "url/gurl.h" |
21 | 20 |
22 #define IPC_MESSAGE_START ChromeExtensionMsgStart | 21 #define IPC_MESSAGE_START ChromeExtensionMsgStart |
23 | 22 |
24 IPC_ENUM_TRAITS_MAX_VALUE(extensions::api::webstore::InstallStage, | 23 IPC_ENUM_TRAITS_MAX_VALUE(extensions::api::webstore::InstallStage, |
25 extensions::api::webstore::INSTALL_STAGE_INSTALLING) | 24 extensions::api::webstore::INSTALL_STAGE_INSTALLING) |
26 IPC_ENUM_TRAITS_MAX_VALUE(extensions::webstore_install::Result, | 25 IPC_ENUM_TRAITS_MAX_VALUE(extensions::webstore_install::Result, |
27 extensions::webstore_install::RESULT_LAST) | 26 extensions::webstore_install::RESULT_LAST) |
28 | 27 |
29 IPC_STRUCT_TRAITS_BEGIN(WebApplicationInfo::IconInfo) | |
30 IPC_STRUCT_TRAITS_MEMBER(url) | |
31 IPC_STRUCT_TRAITS_MEMBER(width) | |
32 IPC_STRUCT_TRAITS_MEMBER(height) | |
33 IPC_STRUCT_TRAITS_MEMBER(data) | |
34 IPC_STRUCT_TRAITS_END() | |
35 | |
36 IPC_STRUCT_TRAITS_BEGIN(WebApplicationInfo) | |
37 IPC_STRUCT_TRAITS_MEMBER(title) | |
38 IPC_STRUCT_TRAITS_MEMBER(description) | |
39 IPC_STRUCT_TRAITS_MEMBER(app_url) | |
40 IPC_STRUCT_TRAITS_MEMBER(icons) | |
41 IPC_STRUCT_TRAITS_END() | |
42 | |
43 // Messages sent from the browser to the renderer. | 28 // Messages sent from the browser to the renderer. |
44 | 29 |
45 // Requests application info for the page. The renderer responds back with | |
46 // ExtensionHostMsg_DidGetApplicationInfo. | |
47 IPC_MESSAGE_ROUTED0(ChromeExtensionMsg_GetApplicationInfo) | |
48 | |
49 // Toggles visual muting of the render view area. This is on when a constrained | 30 // Toggles visual muting of the render view area. This is on when a constrained |
50 // window is showing. | 31 // window is showing. |
51 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetVisuallyDeemphasized, | 32 IPC_MESSAGE_ROUTED1(ChromeViewMsg_SetVisuallyDeemphasized, |
52 bool /* deemphazied */) | 33 bool /* deemphazied */) |
53 | 34 |
54 // Sent to the renderer if install stage updates were requested for an inline | 35 // Sent to the renderer if install stage updates were requested for an inline |
55 // install. | 36 // install. |
56 IPC_MESSAGE_ROUTED1(ExtensionMsg_InlineInstallStageChanged, | 37 IPC_MESSAGE_ROUTED1(ExtensionMsg_InlineInstallStageChanged, |
57 extensions::api::webstore::InstallStage /* stage */) | 38 extensions::api::webstore::InstallStage /* stage */) |
58 | 39 |
(...skipping 13 matching lines...) Expand all Loading... |
72 // Messages sent from the renderer to the browser. | 53 // Messages sent from the renderer to the browser. |
73 | 54 |
74 | 55 |
75 // Sent by the renderer to implement chrome.webstore.install(). | 56 // Sent by the renderer to implement chrome.webstore.install(). |
76 IPC_MESSAGE_ROUTED5(ExtensionHostMsg_InlineWebstoreInstall, | 57 IPC_MESSAGE_ROUTED5(ExtensionHostMsg_InlineWebstoreInstall, |
77 int32 /* install id */, | 58 int32 /* install id */, |
78 int32 /* return route id */, | 59 int32 /* return route id */, |
79 std::string /* Web Store item ID */, | 60 std::string /* Web Store item ID */, |
80 GURL /* requestor URL */, | 61 GURL /* requestor URL */, |
81 int /* listeners_mask */) | 62 int /* listeners_mask */) |
82 | |
83 IPC_MESSAGE_ROUTED1(ChromeExtensionHostMsg_DidGetApplicationInfo, | |
84 WebApplicationInfo) | |
OLD | NEW |