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

Unified Diff: media/audio/win/audio_manager_win.cc

Issue 66183002: Replace MessageLoopProxy with SingleThreadTaskRunner for the rest of media/. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix win and audio tests Created 6 years, 11 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
« no previous file with comments | « media/audio/virtual_audio_output_stream_unittest.cc ('k') | media/base/bind_to_loop_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/win/audio_manager_win.cc
diff --git a/media/audio/win/audio_manager_win.cc b/media/audio/win/audio_manager_win.cc
index 242813a8c65902c6a96e4936d1643ae35a0055cb..5e105dbd8ac24716278e40f9beb61fac19862803 100644
--- a/media/audio/win/audio_manager_win.cc
+++ b/media/audio/win/audio_manager_win.cc
@@ -141,14 +141,14 @@ AudioManagerWin::AudioManagerWin(AudioLogFactory* audio_log_factory)
// Task must be posted last to avoid races from handing out "this" to the
// audio thread.
- GetMessageLoop()->PostTask(FROM_HERE, base::Bind(
+ GetTaskRunner()->PostTask(FROM_HERE, base::Bind(
&AudioManagerWin::CreateDeviceListener, base::Unretained(this)));
}
AudioManagerWin::~AudioManagerWin() {
// It's safe to post a task here since Shutdown() will wait for all tasks to
// complete before returning.
- GetMessageLoop()->PostTask(FROM_HERE, base::Bind(
+ GetTaskRunner()->PostTask(FROM_HERE, base::Bind(
&AudioManagerWin::DestroyDeviceListener, base::Unretained(this)));
Shutdown();
}
@@ -166,7 +166,7 @@ void AudioManagerWin::CreateDeviceListener() {
// be used if WASAPI / Core Audio is supported.
if (CoreAudioUtil::IsSupported()) {
output_device_listener_.reset(new AudioDeviceListenerWin(BindToLoop(
- GetMessageLoop(), base::Bind(
+ GetTaskRunner(), base::Bind(
&AudioManagerWin::NotifyAllOutputDeviceChangeListeners,
base::Unretained(this)))));
}
« no previous file with comments | « media/audio/virtual_audio_output_stream_unittest.cc ('k') | media/base/bind_to_loop_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698