OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 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 | 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, hence no include guard. | 5 // Multiply-included message file, hence no include guard. |
6 | 6 |
7 // This file defines the IPCs for the browser-side implementation of | 7 // This file defines the IPCs for the browser-side implementation of |
8 // WebSockets. | 8 // WebSockets. |
9 // | 9 // |
10 // This IPC interface was originally desined based on the WebSocket | 10 // This IPC interface was originally desined based on the WebSocket |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
124 // DropChannel(was_clean = false, code = 1006, reason = ""). | 124 // DropChannel(was_clean = false, code = 1006, reason = ""). |
125 // |message| will be shown in the inspector and won't be passed to the script. | 125 // |message| will be shown in the inspector and won't be passed to the script. |
126 // TODO(yhirano): Find the way to pass |message| directly to the inspector | 126 // TODO(yhirano): Find the way to pass |message| directly to the inspector |
127 // process. | 127 // process. |
128 IPC_MESSAGE_ROUTED1(WebSocketMsg_NotifyFailure, | 128 IPC_MESSAGE_ROUTED1(WebSocketMsg_NotifyFailure, |
129 std::string /* message */) | 129 std::string /* message */) |
130 | 130 |
131 // Indicates tbat the current Blob has finished sending. The renderer can | 131 // Indicates tbat the current Blob has finished sending. The renderer can |
132 // release its reference on the Blob, and may now use SendFrame or SendBlob to | 132 // release its reference on the Blob, and may now use SendFrame or SendBlob to |
133 // send more messages. | 133 // send more messages. |
134 IPC_MESSAGE_ROUTED0(WebSocketMsg_BlobSendComplete); | 134 IPC_MESSAGE_ROUTED0(WebSocketMsg_BlobSendComplete) |
135 | 135 |
136 // WebSocket messages that can be sent in either direction. | 136 // WebSocket messages that can be sent in either direction. |
137 | 137 |
138 // Send a non-control frame to the channel. | 138 // Send a non-control frame to the channel. |
139 // - If the sender is the renderer, it will be sent to the remote server. | 139 // - If the sender is the renderer, it will be sent to the remote server. |
140 // - If the sender is the browser, it comes from the remote server. | 140 // - If the sender is the browser, it comes from the remote server. |
141 // | 141 // |
142 // - |fin| indicates that this frame is the last in the current message. | 142 // - |fin| indicates that this frame is the last in the current message. |
143 // - |type| is the type of the message. On the first frame of a message, it | 143 // - |type| is the type of the message. On the first frame of a message, it |
144 // must be set to either WEB_SOCKET_MESSAGE_TYPE_TEXT or | 144 // must be set to either WEB_SOCKET_MESSAGE_TYPE_TEXT or |
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
186 // a closing handshake and the renderer cannot accept any new messages on this | 186 // a closing handshake and the renderer cannot accept any new messages on this |
187 // connection. | 187 // connection. |
188 IPC_MESSAGE_ROUTED3(WebSocketMsg_DropChannel, | 188 IPC_MESSAGE_ROUTED3(WebSocketMsg_DropChannel, |
189 bool /* was_clean */, | 189 bool /* was_clean */, |
190 unsigned short /* code */, | 190 unsigned short /* code */, |
191 std::string /* reason */) | 191 std::string /* reason */) |
192 | 192 |
193 // Notify the renderer that a closing handshake has been initiated by the | 193 // Notify the renderer that a closing handshake has been initiated by the |
194 // server, so that it can set the Javascript readyState to CLOSING. | 194 // server, so that it can set the Javascript readyState to CLOSING. |
195 IPC_MESSAGE_ROUTED0(WebSocketMsg_NotifyClosing) | 195 IPC_MESSAGE_ROUTED0(WebSocketMsg_NotifyClosing) |
OLD | NEW |