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

Unified Diff: media/audio/mac/audio_low_latency_input_mac.h

Issue 1911913002: Convert //media/audio from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix cast + windows build Created 4 years, 8 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: media/audio/mac/audio_low_latency_input_mac.h
diff --git a/media/audio/mac/audio_low_latency_input_mac.h b/media/audio/mac/audio_low_latency_input_mac.h
index 07b40a24c45e325b9703bb6728c1093157dad1e8..c883672411c401fa97cb5f8747f33b1e170df31e 100644
--- a/media/audio/mac/audio_low_latency_input_mac.h
+++ b/media/audio/mac/audio_low_latency_input_mac.h
@@ -38,13 +38,14 @@
#include <AudioUnit/AudioUnit.h>
#include <CoreAudio/CoreAudio.h>
+
#include <map>
+#include <memory>
#include <vector>
#include "base/atomicops.h"
#include "base/cancelable_callback.h"
#include "base/macros.h"
-#include "base/memory/scoped_ptr.h"
#include "base/memory/weak_ptr.h"
#include "base/threading/thread_checker.h"
#include "base/time/time.h"
@@ -229,7 +230,7 @@ class MEDIA_EXPORT AUAudioInputStream
// Temporary storage for recorded data. The InputProc() renders into this
// array as soon as a frame of the desired buffer size has been recorded.
- scoped_ptr<uint8_t[]> audio_data_buffer_;
+ std::unique_ptr<uint8_t[]> audio_data_buffer_;
// Fixed capture hardware latency in frames.
double hardware_latency_frames_;
@@ -257,7 +258,7 @@ class MEDIA_EXPORT AUAudioInputStream
// Timer which triggers CheckInputStartupSuccess() to verify that input
// callbacks have started as intended after a successful call to Start().
// This timer lives on the main browser thread.
- scoped_ptr<base::OneShotTimer> input_callback_timer_;
+ std::unique_ptr<base::OneShotTimer> input_callback_timer_;
// Set to true if the Start() call was delayed.
// See AudioManagerMac::ShouldDeferStreamStart() for details.
@@ -301,7 +302,7 @@ class MEDIA_EXPORT AUAudioInputStream
// Timer that provides periodic callbacks used to monitor if the input stream
// is alive or not.
- scoped_ptr<base::RepeatingTimer> check_alive_timer_;
+ std::unique_ptr<base::RepeatingTimer> check_alive_timer_;
// Time tick set once in each input data callback. The time is measured on
// the real-time priority I/O thread but this member is modified and read

Powered by Google App Engine
This is Rietveld 408576698