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

Side by Side Diff: talk/app/webrtc/java/jni/peerconnection_jni.cc

Issue 1640173004: Revert of Adding "first packet received" notification to PeerConnectionObserver. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 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
« no previous file with comments | « no previous file | talk/app/webrtc/java/src/org/webrtc/PeerConnection.java » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2013 Google Inc. 3 * Copyright 2013 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
367 } 367 }
368 368
369 void OnRenegotiationNeeded() override { 369 void OnRenegotiationNeeded() override {
370 ScopedLocalRefFrame local_ref_frame(jni()); 370 ScopedLocalRefFrame local_ref_frame(jni());
371 jmethodID m = 371 jmethodID m =
372 GetMethodID(jni(), *j_observer_class_, "onRenegotiationNeeded", "()V"); 372 GetMethodID(jni(), *j_observer_class_, "onRenegotiationNeeded", "()V");
373 jni()->CallVoidMethod(*j_observer_global_, m); 373 jni()->CallVoidMethod(*j_observer_global_, m);
374 CHECK_EXCEPTION(jni()) << "error during CallVoidMethod"; 374 CHECK_EXCEPTION(jni()) << "error during CallVoidMethod";
375 } 375 }
376 376
377 void OnFirstMediaPacketReceived() override {
378 ScopedLocalRefFrame local_ref_frame(jni());
379 jmethodID m = GetMethodID(jni(), *j_observer_class_,
380 "onFirstMediaPacketReceived", "()V");
381 jni()->CallVoidMethod(*j_observer_global_, m);
382 CHECK_EXCEPTION(jni()) << "error during CallVoidMethod";
383 }
384
385 void SetConstraints(ConstraintsWrapper* constraints) { 377 void SetConstraints(ConstraintsWrapper* constraints) {
386 RTC_CHECK(!constraints_.get()) << "constraints already set!"; 378 RTC_CHECK(!constraints_.get()) << "constraints already set!";
387 constraints_.reset(constraints); 379 constraints_.reset(constraints);
388 } 380 }
389 381
390 const ConstraintsWrapper* constraints() { return constraints_.get(); } 382 const ConstraintsWrapper* constraints() { return constraints_.get(); }
391 383
392 private: 384 private:
393 typedef std::map<MediaStreamInterface*, jobject> NativeToJavaStreamsMap; 385 typedef std::map<MediaStreamInterface*, jobject> NativeToJavaStreamsMap;
394 386
(...skipping 1760 matching lines...) Expand 10 before | Expand all | Expand 10 after
2155 return JavaStringFromStdString( 2147 return JavaStringFromStdString(
2156 jni, 2148 jni,
2157 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->id()); 2149 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->id());
2158 } 2150 }
2159 2151
2160 JOW(void, RtpReceiver_free)(JNIEnv* jni, jclass, jlong j_rtp_receiver_pointer) { 2152 JOW(void, RtpReceiver_free)(JNIEnv* jni, jclass, jlong j_rtp_receiver_pointer) {
2161 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->Release(); 2153 reinterpret_cast<RtpReceiverInterface*>(j_rtp_receiver_pointer)->Release();
2162 } 2154 }
2163 2155
2164 } // namespace webrtc_jni 2156 } // namespace webrtc_jni
OLDNEW
« no previous file with comments | « no previous file | talk/app/webrtc/java/src/org/webrtc/PeerConnection.java » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698