Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(73)

Side by Side Diff: remoting/protocol/libjingle_transport_factory.cc

Issue 1413813006: Revert of Add TransportSession interface to prepare for WebRTC-based transport. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 "remoting/protocol/libjingle_transport_factory.h" 5 #include "remoting/protocol/libjingle_transport_factory.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 8
9 #include "base/callback.h" 9 #include "base/callback.h"
10 #include "base/callback_helpers.h" 10 #include "base/callback_helpers.h"
11 #include "base/single_thread_task_runner.h" 11 #include "base/single_thread_task_runner.h"
12 #include "base/thread_task_runner_handle.h" 12 #include "base/thread_task_runner_handle.h"
13 #include "base/timer/timer.h" 13 #include "base/timer/timer.h"
14 #include "jingle/glue/utils.h" 14 #include "jingle/glue/utils.h"
15 #include "net/base/net_errors.h" 15 #include "net/base/net_errors.h"
16 #include "remoting/protocol/channel_socket_adapter.h" 16 #include "remoting/protocol/channel_socket_adapter.h"
17 #include "remoting/protocol/network_settings.h" 17 #include "remoting/protocol/network_settings.h"
18 #include "remoting/signaling/jingle_info_request.h" 18 #include "remoting/signaling/jingle_info_request.h"
19 #include "third_party/webrtc/base/network.h" 19 #include "third_party/webrtc/base/network.h"
20 #include "third_party/webrtc/p2p/base/constants.h" 20 #include "third_party/webrtc/p2p/base/constants.h"
21 #include "third_party/webrtc/p2p/base/p2ptransportchannel.h" 21 #include "third_party/webrtc/p2p/base/p2ptransportchannel.h"
22 #include "third_party/webrtc/p2p/base/port.h" 22 #include "third_party/webrtc/p2p/base/port.h"
23 #include "third_party/webrtc/p2p/client/basicportallocator.h"
23 #include "third_party/webrtc/p2p/client/httpportallocator.h" 24 #include "third_party/webrtc/p2p/client/httpportallocator.h"
24 25
25 namespace remoting { 26 namespace remoting {
26 namespace protocol { 27 namespace protocol {
27 28
28 namespace { 29 namespace {
29 30
30 // Try connecting ICE twice with timeout of 15 seconds for each attempt. 31 // Try connecting ICE twice with timeout of 15 seconds for each attempt.
31 const int kMaxReconnectAttempts = 2; 32 const int kMaxReconnectAttempts = 2;
32 const int kReconnectDelaySeconds = 15; 33 const int kReconnectDelaySeconds = 15;
(...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
443 last_jingle_info_update_time_ = base::TimeTicks::Now(); 444 last_jingle_info_update_time_ = base::TimeTicks::Now();
444 445
445 while (!on_jingle_info_callbacks_.empty()) { 446 while (!on_jingle_info_callbacks_.empty()) {
446 on_jingle_info_callbacks_.begin()->Run(); 447 on_jingle_info_callbacks_.begin()->Run();
447 on_jingle_info_callbacks_.pop_front(); 448 on_jingle_info_callbacks_.pop_front();
448 } 449 }
449 } 450 }
450 451
451 } // namespace protocol 452 } // namespace protocol
452 } // namespace remoting 453 } // namespace remoting
OLDNEW
« no previous file with comments | « remoting/protocol/libjingle_transport_factory.h ('k') | remoting/protocol/protocol_mock_objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698