OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #include "content/renderer/pepper/pepper_websocket_host.h" | 5 #include "content/renderer/pepper/pepper_websocket_host.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 | 8 |
9 #include "content/public/renderer/renderer_ppapi_host.h" | 9 #include "content/public/renderer/renderer_ppapi_host.h" |
10 #include "net/base/net_util.h" | 10 #include "net/base/port_util.h" |
11 #include "ppapi/c/pp_errors.h" | 11 #include "ppapi/c/pp_errors.h" |
12 #include "ppapi/c/ppb_websocket.h" | 12 #include "ppapi/c/ppb_websocket.h" |
13 #include "ppapi/host/dispatch_host_message.h" | 13 #include "ppapi/host/dispatch_host_message.h" |
14 #include "ppapi/host/host_message_context.h" | 14 #include "ppapi/host/host_message_context.h" |
15 #include "ppapi/host/ppapi_host.h" | 15 #include "ppapi/host/ppapi_host.h" |
16 #include "ppapi/proxy/ppapi_messages.h" | 16 #include "ppapi/proxy/ppapi_messages.h" |
17 #include "third_party/WebKit/public/platform/WebString.h" | 17 #include "third_party/WebKit/public/platform/WebString.h" |
18 #include "third_party/WebKit/public/platform/WebURL.h" | 18 #include "third_party/WebKit/public/platform/WebURL.h" |
19 #include "third_party/WebKit/public/web/WebArrayBuffer.h" | 19 #include "third_party/WebKit/public/web/WebArrayBuffer.h" |
20 #include "third_party/WebKit/public/web/WebDocument.h" | 20 #include "third_party/WebKit/public/web/WebDocument.h" |
(...skipping 298 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
319 | 319 |
320 int32_t PepperWebSocketHost::OnHostMsgFail( | 320 int32_t PepperWebSocketHost::OnHostMsgFail( |
321 ppapi::host::HostMessageContext* context, | 321 ppapi::host::HostMessageContext* context, |
322 const std::string& message) { | 322 const std::string& message) { |
323 if (websocket_) | 323 if (websocket_) |
324 websocket_->fail(WebString::fromUTF8(message)); | 324 websocket_->fail(WebString::fromUTF8(message)); |
325 return PP_OK; | 325 return PP_OK; |
326 } | 326 } |
327 | 327 |
328 } // namespace content | 328 } // namespace content |
OLD | NEW |