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

Side by Side Diff: media/cast/test/utility/udp_proxy_main.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 unified diff | Download patch
« no previous file with comments | « media/cast/test/sender.cc ('k') | media/cdm/aes_decryptor_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <stdint.h> 5 #include <stdint.h>
6 #include <cstdio> 6 #include <cstdio>
7 #include <cstdlib> 7 #include <cstdlib>
8 #include <deque> 8 #include <deque>
9 #include <string> 9 #include <string>
10 #include <utility> 10 #include <utility>
11 11
12 #include "base/at_exit.h" 12 #include "base/at_exit.h"
13 #include "base/bind.h" 13 #include "base/bind.h"
14 #include "base/command_line.h" 14 #include "base/command_line.h"
15 #include "base/lazy_instance.h" 15 #include "base/lazy_instance.h"
16 #include "base/logging.h" 16 #include "base/logging.h"
17 #include "base/message_loop/message_loop.h" 17 #include "base/message_loop/message_loop.h"
18 #include "base/run_loop.h"
18 #include "base/single_thread_task_runner.h" 19 #include "base/single_thread_task_runner.h"
19 #include "base/threading/thread_task_runner_handle.h" 20 #include "base/threading/thread_task_runner_handle.h"
20 #include "media/cast/test/utility/udp_proxy.h" 21 #include "media/cast/test/utility/udp_proxy.h"
21 #include "net/base/ip_address.h" 22 #include "net/base/ip_address.h"
22 23
23 class ByteCounter { 24 class ByteCounter {
24 public: 25 public:
25 ByteCounter() : bytes_(0), packets_(0) { 26 ByteCounter() : bytes_(0), packets_(0) {
26 push(base::TimeTicks::Now()); 27 push(base::TimeTicks::Now());
27 } 28 }
(...skipping 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
194 &(g_counter.Get().out_pipe_output_counter)); 195 &(g_counter.Get().out_pipe_output_counter));
195 196
196 printf("Press Ctrl-C when done.\n"); 197 printf("Press Ctrl-C when done.\n");
197 std::unique_ptr<media::cast::test::UDPProxy> proxy( 198 std::unique_ptr<media::cast::test::UDPProxy> proxy(
198 media::cast::test::UDPProxy::Create(local_endpoint, remote_endpoint, 199 media::cast::test::UDPProxy::Create(local_endpoint, remote_endpoint,
199 std::move(in_pipe), 200 std::move(in_pipe),
200 std::move(out_pipe), NULL)); 201 std::move(out_pipe), NULL));
201 base::MessageLoop message_loop; 202 base::MessageLoop message_loop;
202 g_counter.Get().last_printout = base::TimeTicks::Now(); 203 g_counter.Get().last_printout = base::TimeTicks::Now();
203 CheckByteCounters(); 204 CheckByteCounters();
204 message_loop.Run(); 205 base::RunLoop().Run();
205 return 1; 206 return 1;
206 } 207 }
OLDNEW
« no previous file with comments | « media/cast/test/sender.cc ('k') | media/cdm/aes_decryptor_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698