Chromium Code Reviews| Index: ppapi/api/ppb_websocket.idl |
| diff --git a/ppapi/api/ppb_websocket.idl b/ppapi/api/ppb_websocket.idl |
| index 1e138bb80b47bf8a405a99177edef010c7321f7d..2d80b51097ca64661e996fcc01db3d851030a6a2 100644 |
| --- a/ppapi/api/ppb_websocket.idl |
| +++ b/ppapi/api/ppb_websocket.idl |
| @@ -56,7 +56,14 @@ enum PP_WebSocketReadyState { |
| * <code>PP_WEBSOCKETSTATUSCODE_USER_PRIVATE_MAX</code> are valid for Close(). |
| */ |
| [assert_size(4)] |
| -enum PP_WebSocketCloseCode { |
| +enum PP_WebSocketStatusCode { |
| + /** |
| + * Indicates to request closing connection without status code. This code is |
| + * internally assigned in WebKit, and not based on any WebSocket related |
| + * specification. |
| + */ |
| + PP_WEBSOCKETSTATUSCODE_NOT_SPECIFIED = -1, |
| + |
| /** |
| * Status codes in the range 0-999 are not used. |
| */ |
| @@ -244,7 +251,8 @@ interface PPB_WebSocket { |
| * @param[in] web_socket A <code>PP_Resource</code> corresponding to a |
| * WebSocket. |
| * |
| - * @param[in] code The WebSocket close code. This is ignored if it is 0. |
|
dmichael (off chromium)
2012/05/15 15:18:33
So, what does ignored mean in this case? When the
Takashi Toyoshima
2012/05/16 09:20:32
When I defined this API, I think I can use '0' to
|
| + * @param[in] code The WebSocket close code. This is ignored if it is |
| + * <code>PP_WEBSOCKETSTATUSCODE_NOT_SPECIFIED</code>. |
| * <code>PP_WEBSOCKETSTATUSCODE_NORMAL_CLOSURE</code> must be used for the |
| * usual case. To indicate some specific error cases, codes in the range |
| * <code>PP_WEBSOCKETSTATUSCODE_USER_REGISTERED_MIN</code> to |
| @@ -273,7 +281,7 @@ interface PPB_WebSocket { |
| * not finished. |
| */ |
| int32_t Close([in] PP_Resource web_socket, |
| - [in] uint16_t code, |
|
dmichael (off chromium)
2012/05/15 15:18:33
Ack... I'm sorry, I didn't realize you were using
Takashi Toyoshima
2012/05/16 09:20:32
I guess uint16_t argument is compatible to one of
|
| + [in] PP_WebSocketStatusCode code, |
| [in] PP_Var reason, |
| [in] PP_CompletionCallback callback); |