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

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

Issue 12210030: Linux/ChromeOS Chromium style checker cleanup, content/ edition. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 7 years, 10 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 | Annotate | Revision Log
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> 7 #include <string>
8 #include <utility> 8 #include <utility>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 209 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 }; 220 };
221 221
222 // Class mapping responses from calls to libjingle 222 // Class mapping responses from calls to libjingle
223 // GetStats into a WebKit::WebRTCStatsCallback. 223 // GetStats into a WebKit::WebRTCStatsCallback.
224 class StatsResponse : public webrtc::StatsObserver { 224 class StatsResponse : public webrtc::StatsObserver {
225 public: 225 public:
226 explicit StatsResponse(const scoped_refptr<LocalRTCStatsRequest>& request) 226 explicit StatsResponse(const scoped_refptr<LocalRTCStatsRequest>& request)
227 : request_(request), 227 : request_(request),
228 response_(request_->createResponse()) {} 228 response_(request_->createResponse()) {}
229 229
230 virtual void OnComplete(const std::vector<webrtc::StatsReport>& reports) { 230 virtual void OnComplete(
231 const std::vector<webrtc::StatsReport>& reports) OVERRIDE {
231 for (std::vector<webrtc::StatsReport>::const_iterator it = reports.begin(); 232 for (std::vector<webrtc::StatsReport>::const_iterator it = reports.begin();
232 it != reports.end(); ++it) { 233 it != reports.end(); ++it) {
233 int idx = response_->addReport(); 234 int idx = response_->addReport();
234 if (it->local.values.size() > 0) { 235 if (it->local.values.size() > 0) {
235 AddElement(idx, true, it->id, it->type, it->local); 236 AddElement(idx, true, it->id, it->type, it->local);
236 } 237 }
237 if (it->remote.values.size() > 0) { 238 if (it->remote.values.size() > 0) {
238 AddElement(idx, false, it->id, it->type, it->remote); 239 AddElement(idx, false, it->id, it->type, it->remote);
239 } 240 }
240 } 241 }
(...skipping 509 matching lines...) Expand 10 before | Expand all | Expand 10 after
750 webrtc::SessionDescriptionInterface* native_desc = 751 webrtc::SessionDescriptionInterface* native_desc =
751 dependency_factory_->CreateSessionDescription(type, sdp, error); 752 dependency_factory_->CreateSessionDescription(type, sdp, error);
752 753
753 LOG_IF(ERROR, !native_desc) << "Failed to create native session description." 754 LOG_IF(ERROR, !native_desc) << "Failed to create native session description."
754 << " Type: " << type << " SDP: " << sdp; 755 << " Type: " << type << " SDP: " << sdp;
755 756
756 return native_desc; 757 return native_desc;
757 } 758 }
758 759
759 } // namespace content 760 } // namespace content
OLDNEW
« no previous file with comments | « content/renderer/media/mock_peer_connection_impl.cc ('k') | content/renderer/media/rtc_peer_connection_handler_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698