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

Side by Side Diff: third_party/WebKit/Source/modules/peerconnection/RTCPeerConnection.cpp

Issue 2681903002: RAPPOR metric for usage of RTCPeerConnection without connecting. (Closed)
Patch Set: Created 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2012 Google Inc. All rights reserved. 2 * Copyright (C) 2012 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 1394 matching lines...) Expand 10 before | Expand all | Expand 10 after
1405 } 1405 }
1406 1406
1407 void RTCPeerConnection::closeInternal() { 1407 void RTCPeerConnection::closeInternal() {
1408 DCHECK(m_signalingState != RTCPeerConnection::SignalingStateClosed); 1408 DCHECK(m_signalingState != RTCPeerConnection::SignalingStateClosed);
1409 m_peerHandler->stop(); 1409 m_peerHandler->stop();
1410 m_closed = true; 1410 m_closed = true;
1411 1411
1412 changeIceConnectionState(ICEConnectionStateClosed); 1412 changeIceConnectionState(ICEConnectionStateClosed);
1413 changeIceGatheringState(ICEGatheringStateComplete); 1413 changeIceGatheringState(ICEGatheringStateComplete);
1414 changeSignalingState(SignalingStateClosed); 1414 changeSignalingState(SignalingStateClosed);
1415 Document* document = toDocument(getExecutionContext());
1416 HostsUsingFeatures::countAnyWorld(
1417 *document, HostsUsingFeatures::Feature::RTCPeerConnectionUsed);
1415 } 1418 }
1416 1419
1417 void RTCPeerConnection::scheduleDispatchEvent(Event* event) { 1420 void RTCPeerConnection::scheduleDispatchEvent(Event* event) {
1418 scheduleDispatchEvent(event, nullptr); 1421 scheduleDispatchEvent(event, nullptr);
1419 } 1422 }
1420 1423
1421 void RTCPeerConnection::scheduleDispatchEvent( 1424 void RTCPeerConnection::scheduleDispatchEvent(
1422 Event* event, 1425 Event* event,
1423 std::unique_ptr<BoolFunction> setupFunction) { 1426 std::unique_ptr<BoolFunction> setupFunction) {
1424 m_scheduledEvents.push_back( 1427 m_scheduledEvents.push_back(
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
1472 DEFINE_TRACE(RTCPeerConnection) { 1475 DEFINE_TRACE(RTCPeerConnection) {
1473 visitor->trace(m_localStreams); 1476 visitor->trace(m_localStreams);
1474 visitor->trace(m_remoteStreams); 1477 visitor->trace(m_remoteStreams);
1475 visitor->trace(m_dispatchScheduledEventRunner); 1478 visitor->trace(m_dispatchScheduledEventRunner);
1476 visitor->trace(m_scheduledEvents); 1479 visitor->trace(m_scheduledEvents);
1477 EventTargetWithInlineData::trace(visitor); 1480 EventTargetWithInlineData::trace(visitor);
1478 SuspendableObject::trace(visitor); 1481 SuspendableObject::trace(visitor);
1479 } 1482 }
1480 1483
1481 } // namespace blink 1484 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/frame/HostsUsingFeatures.cpp ('k') | tools/metrics/rappor/rappor.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698