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

Side by Side Diff: content/renderer/media/rtc_peer_connection_handler.cc

Issue 1855193002: Move the call to enable the WebRTC event log from PeerConnectionFactory to PeerConnection. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added CONTENT_EXPORT to WebRTCEventLogHost. Created 4 years, 5 months 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 "content/renderer/media/rtc_peer_connection_handler.h" 5 #include "content/renderer/media/rtc_peer_connection_handler.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 8
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
(...skipping 1419 matching lines...) Expand 10 before | Expand all | Expand 10 after
1430 base::Bind(&GetStatsOnSignalingThread, native_peer_connection_, level, 1430 base::Bind(&GetStatsOnSignalingThread, native_peer_connection_, level,
1431 make_scoped_refptr(observer), track_id, track_type)); 1431 make_scoped_refptr(observer), track_id, track_type));
1432 } 1432 }
1433 1433
1434 void RTCPeerConnectionHandler::CloseClientPeerConnection() { 1434 void RTCPeerConnectionHandler::CloseClientPeerConnection() {
1435 DCHECK(thread_checker_.CalledOnValidThread()); 1435 DCHECK(thread_checker_.CalledOnValidThread());
1436 if (!is_closed_) 1436 if (!is_closed_)
1437 client_->closePeerConnection(); 1437 client_->closePeerConnection();
1438 } 1438 }
1439 1439
1440 void RTCPeerConnectionHandler::StartEventLog(IPC::PlatformFileForTransit file,
1441 int64_t max_file_size_bytes) {
1442 DCHECK(thread_checker_.CalledOnValidThread());
1443 DCHECK(file != IPC::InvalidPlatformFileForTransit());
1444 native_peer_connection_->StartRtcEventLog(
1445 IPC::PlatformFileForTransitToPlatformFile(file), max_file_size_bytes);
1446 }
1447
1448 void RTCPeerConnectionHandler::StopEventLog() {
1449 DCHECK(thread_checker_.CalledOnValidThread());
1450 native_peer_connection_->StopRtcEventLog();
1451 }
1452
1440 blink::WebRTCDataChannelHandler* RTCPeerConnectionHandler::createDataChannel( 1453 blink::WebRTCDataChannelHandler* RTCPeerConnectionHandler::createDataChannel(
1441 const blink::WebString& label, const blink::WebRTCDataChannelInit& init) { 1454 const blink::WebString& label, const blink::WebRTCDataChannelInit& init) {
1442 DCHECK(thread_checker_.CalledOnValidThread()); 1455 DCHECK(thread_checker_.CalledOnValidThread());
1443 TRACE_EVENT0("webrtc", "RTCPeerConnectionHandler::createDataChannel"); 1456 TRACE_EVENT0("webrtc", "RTCPeerConnectionHandler::createDataChannel");
1444 DVLOG(1) << "createDataChannel label " 1457 DVLOG(1) << "createDataChannel label "
1445 << base::UTF16ToUTF8(base::StringPiece16(label)); 1458 << base::UTF16ToUTF8(base::StringPiece16(label));
1446 1459
1447 webrtc::DataChannelInit config; 1460 webrtc::DataChannelInit config;
1448 // TODO(jiayl): remove the deprecated reliable field once Libjingle is updated 1461 // TODO(jiayl): remove the deprecated reliable field once Libjingle is updated
1449 // to handle that. 1462 // to handle that.
(...skipping 342 matching lines...) Expand 10 before | Expand all | Expand 10 after
1792 } 1805 }
1793 1806
1794 void RTCPeerConnectionHandler::ResetUMAStats() { 1807 void RTCPeerConnectionHandler::ResetUMAStats() {
1795 DCHECK(thread_checker_.CalledOnValidThread()); 1808 DCHECK(thread_checker_.CalledOnValidThread());
1796 num_local_candidates_ipv6_ = 0; 1809 num_local_candidates_ipv6_ = 0;
1797 num_local_candidates_ipv4_ = 0; 1810 num_local_candidates_ipv4_ = 0;
1798 ice_connection_checking_start_ = base::TimeTicks(); 1811 ice_connection_checking_start_ = base::TimeTicks();
1799 memset(ice_state_seen_, 0, sizeof(ice_state_seen_)); 1812 memset(ice_state_seen_, 0, sizeof(ice_state_seen_));
1800 } 1813 }
1801 } // namespace content 1814 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698