| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // Multiply-included message file, no traditional include guard. | 5 // Multiply-included message file, no traditional include guard. |
| 6 #include <string> | 6 #include <string> |
| 7 | 7 |
| 8 #include "chrome/common/remoting/chromoting_host_info.h" | |
| 9 #include "ipc/ipc_channel_handle.h" | 8 #include "ipc/ipc_channel_handle.h" |
| 10 #include "ipc/ipc_message_macros.h" | 9 #include "ipc/ipc_message_macros.h" |
| 11 | 10 |
| 12 #define IPC_MESSAGE_START ServiceMsgStart | 11 #define IPC_MESSAGE_START ServiceMsgStart |
| 13 | 12 |
| 14 IPC_STRUCT_TRAITS_BEGIN(remoting::ChromotingHostInfo) | |
| 15 IPC_STRUCT_TRAITS_MEMBER(host_id) | |
| 16 IPC_STRUCT_TRAITS_MEMBER(hostname) | |
| 17 IPC_STRUCT_TRAITS_MEMBER(public_key) | |
| 18 IPC_STRUCT_TRAITS_MEMBER(enabled) | |
| 19 IPC_STRUCT_TRAITS_MEMBER(login) | |
| 20 IPC_STRUCT_TRAITS_END() | |
| 21 | |
| 22 //----------------------------------------------------------------------------- | 13 //----------------------------------------------------------------------------- |
| 23 // Service process messages: | 14 // Service process messages: |
| 24 // These are messages from the browser to the service process. | 15 // These are messages from the browser to the service process. |
| 25 // Tell the service process to enable the cloud proxy passing in the lsid | 16 // Tell the service process to enable the cloud proxy passing in the lsid |
| 26 // of the account to be used. | 17 // of the account to be used. |
| 27 IPC_MESSAGE_CONTROL1(ServiceMsg_EnableCloudPrintProxy, | 18 IPC_MESSAGE_CONTROL1(ServiceMsg_EnableCloudPrintProxy, |
| 28 std::string /* lsid */) | 19 std::string /* lsid */) |
| 29 // Tell the service process to enable the cloud proxy passing in specific | 20 // Tell the service process to enable the cloud proxy passing in specific |
| 30 // tokens to be used. | 21 // tokens to be used. |
| 31 IPC_MESSAGE_CONTROL2(ServiceMsg_EnableCloudPrintProxyWithTokens, | 22 IPC_MESSAGE_CONTROL2(ServiceMsg_EnableCloudPrintProxyWithTokens, |
| 32 std::string, /* token for cloudprint service */ | 23 std::string, /* token for cloudprint service */ |
| 33 std::string /* token for Google Talk service */) | 24 std::string /* token for Google Talk service */) |
| 34 // Tell the service process to disable the cloud proxy. | 25 // Tell the service process to disable the cloud proxy. |
| 35 IPC_MESSAGE_CONTROL0(ServiceMsg_DisableCloudPrintProxy) | 26 IPC_MESSAGE_CONTROL0(ServiceMsg_DisableCloudPrintProxy) |
| 36 | 27 |
| 37 // Requests a message back on whether the cloud print proxy is | 28 // Requests a message back on whether the cloud print proxy is |
| 38 // enabled. | 29 // enabled. |
| 39 IPC_MESSAGE_CONTROL0(ServiceMsg_IsCloudPrintProxyEnabled) | 30 IPC_MESSAGE_CONTROL0(ServiceMsg_IsCloudPrintProxyEnabled) |
| 40 | 31 |
| 41 // Set credentials used by the RemotingHost. | |
| 42 IPC_MESSAGE_CONTROL2(ServiceMsg_SetRemotingHostCredentials, | |
| 43 std::string, /* username */ | |
| 44 std::string /* token for XMPP */) | |
| 45 | |
| 46 // Enabled remoting host. | |
| 47 IPC_MESSAGE_CONTROL0(ServiceMsg_EnableRemotingHost) | |
| 48 | |
| 49 // Disable remoting host. | |
| 50 IPC_MESSAGE_CONTROL0(ServiceMsg_DisableRemotingHost) | |
| 51 | |
| 52 // Get remoting host status information. | |
| 53 IPC_MESSAGE_CONTROL0(ServiceMsg_GetRemotingHostInfo) | |
| 54 | |
| 55 // Tell the service process to shutdown. | 32 // Tell the service process to shutdown. |
| 56 IPC_MESSAGE_CONTROL0(ServiceMsg_Shutdown) | 33 IPC_MESSAGE_CONTROL0(ServiceMsg_Shutdown) |
| 57 | 34 |
| 58 // Tell the service process that an update is available. | 35 // Tell the service process that an update is available. |
| 59 IPC_MESSAGE_CONTROL0(ServiceMsg_UpdateAvailable) | 36 IPC_MESSAGE_CONTROL0(ServiceMsg_UpdateAvailable) |
| 60 | 37 |
| 61 //----------------------------------------------------------------------------- | 38 //----------------------------------------------------------------------------- |
| 62 // Service process host messages: | 39 // Service process host messages: |
| 63 // These are messages from the service process to the browser. | 40 // These are messages from the service process to the browser. |
| 64 // Sent when the cloud print proxy has an authentication error. | 41 // Sent when the cloud print proxy has an authentication error. |
| 65 IPC_MESSAGE_CONTROL0(ServiceHostMsg_CloudPrintProxy_AuthError) | 42 IPC_MESSAGE_CONTROL0(ServiceHostMsg_CloudPrintProxy_AuthError) |
| 66 | 43 |
| 67 // Sent as a response to a request for enablement status. | 44 // Sent as a response to a request for enablement status. |
| 68 IPC_MESSAGE_CONTROL2(ServiceHostMsg_CloudPrintProxy_IsEnabled, | 45 IPC_MESSAGE_CONTROL2(ServiceHostMsg_CloudPrintProxy_IsEnabled, |
| 69 bool, /* Is the proxy enabled? */ | 46 bool, /* Is the proxy enabled? */ |
| 70 std::string /* Email address of account */) | 47 std::string /* Email address of account */) |
| 71 | |
| 72 IPC_MESSAGE_CONTROL1(ServiceHostMsg_RemotingHost_HostInfo, | |
| 73 remoting::ChromotingHostInfo /* host_info */) | |
| 74 | |
| OLD | NEW |