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

Unified Diff: media/cast/test/sender.cc

Issue 2086353002: Remove calls to deprecated MessageLoop methods in media. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 4 years, 6 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/cast/test/receiver.cc ('k') | media/cast/test/utility/udp_proxy_main.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cast/test/sender.cc
diff --git a/media/cast/test/sender.cc b/media/cast/test/sender.cc
index 842440baa6a205118068c18076fd920b8a020e6e..0938377a8fe03e0749fe58e60ba1ca981c6a172b 100644
--- a/media/cast/test/sender.cc
+++ b/media/cast/test/sender.cc
@@ -19,6 +19,7 @@
#include "base/logging.h"
#include "base/memory/ptr_util.h"
#include "base/path_service.h"
+#include "base/single_thread_task_runner.h"
#include "base/strings/string_number_conversions.h"
#include "base/threading/thread.h"
#include "base/time/default_tick_clock.h"
@@ -334,7 +335,7 @@ int main(int argc, char** argv) {
// CastSender initialization.
std::unique_ptr<media::cast::CastSender> cast_sender =
media::cast::CastSender::Create(cast_environment, transport_sender.get());
- io_message_loop.PostTask(
+ io_message_loop.task_runner()->PostTask(
FROM_HERE,
base::Bind(&media::cast::CastSender::InitializeVideo,
base::Unretained(cast_sender.get()),
@@ -343,12 +344,10 @@ int main(int argc, char** argv) {
media::cast::CreateDefaultVideoEncodeAcceleratorCallback(),
media::cast::CreateDefaultVideoEncodeMemoryCallback()));
io_message_loop.Run(); // Wait for video initialization.
- io_message_loop.PostTask(
- FROM_HERE,
- base::Bind(&media::cast::CastSender::InitializeAudio,
- base::Unretained(cast_sender.get()),
- audio_config,
- base::Bind(&QuitLoopOnInitializationResult)));
+ io_message_loop.task_runner()->PostTask(
+ FROM_HERE, base::Bind(&media::cast::CastSender::InitializeAudio,
+ base::Unretained(cast_sender.get()), audio_config,
+ base::Bind(&QuitLoopOnInitializationResult)));
io_message_loop.Run(); // Wait for audio initialization.
fake_media_source->Start(cast_sender->audio_frame_input(),
« no previous file with comments | « media/cast/test/receiver.cc ('k') | media/cast/test/utility/udp_proxy_main.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698