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

Unified Diff: third_party/WebKit/Source/platform/audio/AudioDestination.cpp

Issue 2359553003: Replaced PassRefPtr copies with moves. (Closed)
Patch Set: Created 4 years, 3 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: third_party/WebKit/Source/platform/audio/AudioDestination.cpp
diff --git a/third_party/WebKit/Source/platform/audio/AudioDestination.cpp b/third_party/WebKit/Source/platform/audio/AudioDestination.cpp
index f8f27dda9d98bc9b2b18ed0d7e69812aba3dd691..cc85f602782f2f9fe0414dbdb3f9b5253da12b3e 100644
--- a/third_party/WebKit/Source/platform/audio/AudioDestination.cpp
+++ b/third_party/WebKit/Source/platform/audio/AudioDestination.cpp
@@ -48,7 +48,7 @@ const size_t fifoSize = 8192;
// Factory method: Chromium-implementation
std::unique_ptr<AudioDestination> AudioDestination::create(AudioIOCallback& callback, const String& inputDeviceId, unsigned numberOfInputChannels, unsigned numberOfOutputChannels, float sampleRate, PassRefPtr<SecurityOrigin> securityOrigin)
{
- return wrapUnique(new AudioDestination(callback, inputDeviceId, numberOfInputChannels, numberOfOutputChannels, sampleRate, securityOrigin));
+ return wrapUnique(new AudioDestination(callback, inputDeviceId, numberOfInputChannels, numberOfOutputChannels, sampleRate, std::move(securityOrigin)));
}
AudioDestination::AudioDestination(AudioIOCallback& callback, const String& inputDeviceId, unsigned numberOfInputChannels, unsigned numberOfOutputChannels, float sampleRate, PassRefPtr<SecurityOrigin> securityOrigin)
@@ -92,7 +92,7 @@ AudioDestination::AudioDestination(AudioIOCallback& callback, const String& inpu
if (m_callbackBufferSize + renderBufferSize > fifoSize)
return;
- m_audioDevice = wrapUnique(Platform::current()->createAudioDevice(m_callbackBufferSize, numberOfInputChannels, numberOfOutputChannels, sampleRate, this, inputDeviceId, securityOrigin));
+ m_audioDevice = wrapUnique(Platform::current()->createAudioDevice(m_callbackBufferSize, numberOfInputChannels, numberOfOutputChannels, sampleRate, this, inputDeviceId, std::move(securityOrigin)));
ASSERT(m_audioDevice);
// Record the sizes if we successfully created an output device.
« no previous file with comments | « third_party/WebKit/Source/platform/Length.cpp ('k') | third_party/WebKit/Source/platform/blob/BlobRegistry.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698