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/p2p/ipc_network_manager.h" | 5 #include "content/renderer/p2p/ipc_network_manager.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include "base/bind.h" | 8 #include "base/bind.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/location.h" | 10 #include "base/location.h" |
11 #include "base/metrics/histogram.h" | 11 #include "base/metrics/histogram.h" |
12 #include "base/single_thread_task_runner.h" | 12 #include "base/single_thread_task_runner.h" |
13 #include "base/sys_byteorder.h" | 13 #include "base/sys_byteorder.h" |
14 #include "base/thread_task_runner_handle.h" | 14 #include "base/thread_task_runner_handle.h" |
15 #include "content/public/common/content_switches.h" | 15 #include "content/public/common/content_switches.h" |
| 16 #include "net/base/ip_address_number.h" |
16 #include "net/base/net_util.h" | 17 #include "net/base/net_util.h" |
| 18 #include "net/base/network_change_notifier.h" |
17 | 19 |
18 namespace content { | 20 namespace content { |
19 | 21 |
20 namespace { | 22 namespace { |
21 | 23 |
22 rtc::AdapterType ConvertConnectionTypeToAdapterType( | 24 rtc::AdapterType ConvertConnectionTypeToAdapterType( |
23 net::NetworkChangeNotifier::ConnectionType type) { | 25 net::NetworkChangeNotifier::ConnectionType type) { |
24 switch (type) { | 26 switch (type) { |
25 case net::NetworkChangeNotifier::CONNECTION_UNKNOWN: | 27 case net::NetworkChangeNotifier::CONNECTION_UNKNOWN: |
26 return rtc::ADAPTER_TYPE_UNKNOWN; | 28 return rtc::ADAPTER_TYPE_UNKNOWN; |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 stats.ipv4_network_count); | 143 stats.ipv4_network_count); |
142 UMA_HISTOGRAM_COUNTS_100("WebRTC.PeerConnection.IPv6Interfaces", | 144 UMA_HISTOGRAM_COUNTS_100("WebRTC.PeerConnection.IPv6Interfaces", |
143 stats.ipv6_network_count); | 145 stats.ipv6_network_count); |
144 } | 146 } |
145 | 147 |
146 void IpcNetworkManager::SendNetworksChangedSignal() { | 148 void IpcNetworkManager::SendNetworksChangedSignal() { |
147 SignalNetworksChanged(); | 149 SignalNetworksChanged(); |
148 } | 150 } |
149 | 151 |
150 } // namespace content | 152 } // namespace content |
OLD | NEW |