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/media/rtc_peer_connection_handler.h" | 5 #include "content/renderer/media/rtc_peer_connection_handler.h" |
6 | 6 |
7 #include <string> | 7 #include <string> |
8 #include <utility> | 8 #include <utility> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 764 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
775 TRACE_EVENT0("webrtc", "RTCPeerConnectionHandler::GetStats"); | 775 TRACE_EVENT0("webrtc", "RTCPeerConnectionHandler::GetStats"); |
776 if (!native_peer_connection_->GetStats(observer, track, level)) { | 776 if (!native_peer_connection_->GetStats(observer, track, level)) { |
777 DVLOG(1) << "GetStats failed."; | 777 DVLOG(1) << "GetStats failed."; |
778 // TODO(hta): Consider how to get an error back. | 778 // TODO(hta): Consider how to get an error back. |
779 std::vector<webrtc::StatsReport> no_reports; | 779 std::vector<webrtc::StatsReport> no_reports; |
780 observer->OnComplete(no_reports); | 780 observer->OnComplete(no_reports); |
781 return; | 781 return; |
782 } | 782 } |
783 } | 783 } |
784 | 784 |
785 void RTCPeerConnectionHandler::CloseClientPeerConnection() { | |
786 client_->closePeerConnection(); | |
787 } | |
788 | |
789 blink::WebRTCDataChannelHandler* RTCPeerConnectionHandler::createDataChannel( | 785 blink::WebRTCDataChannelHandler* RTCPeerConnectionHandler::createDataChannel( |
790 const blink::WebString& label, const blink::WebRTCDataChannelInit& init) { | 786 const blink::WebString& label, const blink::WebRTCDataChannelInit& init) { |
791 DVLOG(1) << "createDataChannel label " << base::UTF16ToUTF8(label); | 787 DVLOG(1) << "createDataChannel label " << base::UTF16ToUTF8(label); |
792 | 788 |
793 webrtc::DataChannelInit config; | 789 webrtc::DataChannelInit config; |
794 // TODO(jiayl): remove the deprecated reliable field once Libjingle is updated | 790 // TODO(jiayl): remove the deprecated reliable field once Libjingle is updated |
795 // to handle that. | 791 // to handle that. |
796 config.reliable = false; | 792 config.reliable = false; |
797 config.id = init.id; | 793 config.id = init.id; |
798 config.ordered = init.ordered; | 794 config.ordered = init.ordered; |
(...skipping 202 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1001 webrtc::SessionDescriptionInterface* native_desc = | 997 webrtc::SessionDescriptionInterface* native_desc = |
1002 dependency_factory_->CreateSessionDescription(type, sdp, error); | 998 dependency_factory_->CreateSessionDescription(type, sdp, error); |
1003 | 999 |
1004 LOG_IF(ERROR, !native_desc) << "Failed to create native session description." | 1000 LOG_IF(ERROR, !native_desc) << "Failed to create native session description." |
1005 << " Type: " << type << " SDP: " << sdp; | 1001 << " Type: " << type << " SDP: " << sdp; |
1006 | 1002 |
1007 return native_desc; | 1003 return native_desc; |
1008 } | 1004 } |
1009 | 1005 |
1010 } // namespace content | 1006 } // namespace content |
OLD | NEW |