OLD | NEW |
1 // Copyright (c) 2011 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 #include "content/renderer/p2p/p2p_transport_impl.h" | 5 #include "content/renderer/p2p/p2p_transport_impl.h" |
6 | 6 |
7 #include "content/renderer/p2p/ipc_network_manager.h" | 7 #include "content/renderer/p2p/ipc_network_manager.h" |
8 #include "content/renderer/p2p/ipc_socket_factory.h" | 8 #include "content/renderer/p2p/ipc_socket_factory.h" |
9 #include "content/renderer/p2p/port_allocator.h" | 9 #include "content/renderer/p2p/port_allocator.h" |
10 #include "content/renderer/render_view.h" | |
11 #include "jingle/glue/channel_socket_adapter.h" | 10 #include "jingle/glue/channel_socket_adapter.h" |
12 #include "jingle/glue/pseudotcp_adapter.h" | 11 #include "jingle/glue/pseudotcp_adapter.h" |
13 #include "jingle/glue/thread_wrapper.h" | 12 #include "jingle/glue/thread_wrapper.h" |
14 #include "jingle/glue/utils.h" | 13 #include "jingle/glue/utils.h" |
15 #include "net/base/net_errors.h" | 14 #include "net/base/net_errors.h" |
16 #include "third_party/libjingle/source/talk/p2p/base/p2ptransportchannel.h" | 15 #include "third_party/libjingle/source/talk/p2p/base/p2ptransportchannel.h" |
17 #include "third_party/libjingle/source/talk/p2p/client/basicportallocator.h" | 16 #include "third_party/libjingle/source/talk/p2p/client/basicportallocator.h" |
18 | 17 |
19 namespace content { | 18 namespace content { |
20 | 19 |
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
155 void P2PTransportImpl::OnTcpConnected(int result) { | 154 void P2PTransportImpl::OnTcpConnected(int result) { |
156 if (result < 0) { | 155 if (result < 0) { |
157 event_handler_->OnError(result); | 156 event_handler_->OnError(result); |
158 return; | 157 return; |
159 } | 158 } |
160 state_ = static_cast<State>(STATE_READABLE | STATE_WRITABLE); | 159 state_ = static_cast<State>(STATE_READABLE | STATE_WRITABLE); |
161 event_handler_->OnStateChange(state_); | 160 event_handler_->OnStateChange(state_); |
162 } | 161 } |
163 | 162 |
164 } // namespace content | 163 } // namespace content |
OLD | NEW |