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

Unified Diff: webrtc/modules/audio_device/android/audio_record_jni.h

Issue 1722083002: Replace scoped_ptr with unique_ptr in webrtc/modules/audio_device/ (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 side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_device/android/audio_record_jni.h
diff --git a/webrtc/modules/audio_device/android/audio_record_jni.h b/webrtc/modules/audio_device/android/audio_record_jni.h
index 766316a83aefd45de7c53a4d2b00de2a7dd9a358..13194939b691ad8d310693b476d962f6e4b55ced 100644
--- a/webrtc/modules/audio_device/android/audio_record_jni.h
+++ b/webrtc/modules/audio_device/android/audio_record_jni.h
@@ -11,6 +11,8 @@
#ifndef WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_RECORD_JNI_H_
#define WEBRTC_MODULES_AUDIO_DEVICE_ANDROID_AUDIO_RECORD_JNI_H_
+#include <memory>
+
#include <jni.h>
#include "webrtc/base/thread_checker.h"
@@ -46,7 +48,7 @@ class AudioRecordJni {
class JavaAudioRecord {
public:
JavaAudioRecord(NativeRegistration* native_registration,
- rtc::scoped_ptr<GlobalRef> audio_track);
+ std::unique_ptr<GlobalRef> audio_track);
~JavaAudioRecord();
int InitRecording(int sample_rate, size_t channels);
@@ -57,7 +59,7 @@ class AudioRecordJni {
bool EnableBuiltInNS(bool enable);
private:
- rtc::scoped_ptr<GlobalRef> audio_record_;
+ std::unique_ptr<GlobalRef> audio_record_;
jmethodID init_recording_;
jmethodID start_recording_;
jmethodID stop_recording_;
@@ -117,13 +119,13 @@ class AudioRecordJni {
AttachCurrentThreadIfNeeded attach_thread_if_needed_;
// Wraps the JNI interface pointer and methods associated with it.
- rtc::scoped_ptr<JNIEnvironment> j_environment_;
+ std::unique_ptr<JNIEnvironment> j_environment_;
// Contains factory method for creating the Java object.
- rtc::scoped_ptr<NativeRegistration> j_native_registration_;
+ std::unique_ptr<NativeRegistration> j_native_registration_;
// Wraps the Java specific parts of the AudioRecordJni class.
- rtc::scoped_ptr<AudioRecordJni::JavaAudioRecord> j_audio_record_;
+ std::unique_ptr<AudioRecordJni::JavaAudioRecord> j_audio_record_;
// Raw pointer to the audio manger.
const AudioManager* audio_manager_;
« no previous file with comments | « webrtc/modules/audio_device/android/audio_manager_unittest.cc ('k') | webrtc/modules/audio_device/android/audio_record_jni.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698