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

Side by Side Diff: chromecast/browser/media/cma_message_loop.h

Issue 1142513004: Chromecast: MessageLoopProxy cleanup --> SingleThreadTaskRunner. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: rebase Created 5 years, 7 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
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 #ifndef CHROMECAST_BROWSER_MEDIA_CMA_MESSAGE_LOOP_H_ 5 #ifndef CHROMECAST_BROWSER_MEDIA_CMA_MESSAGE_LOOP_H_
6 #define CHROMECAST_BROWSER_MEDIA_CMA_MESSAGE_LOOP_H_ 6 #define CHROMECAST_BROWSER_MEDIA_CMA_MESSAGE_LOOP_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/memory/ref_counted.h" 9 #include "base/memory/ref_counted.h"
10 #include "base/memory/singleton.h" 10 #include "base/memory/singleton.h"
11 11
12 namespace base { 12 namespace base {
13 class MessageLoopProxy;
14 class SingleThreadTaskRunner; 13 class SingleThreadTaskRunner;
15 class Thread; 14 class Thread;
16 } 15 }
17 16
18 namespace chromecast { 17 namespace chromecast {
19 namespace media { 18 namespace media {
20 19
21 class CmaMessageLoop { 20 class CmaMessageLoop {
22 public: 21 public:
23 // TODO(gunsch): clean up references to deprecated Message*Loop*Proxy.
24 static scoped_refptr<base::MessageLoopProxy> GetMessageLoopProxy();
25 static scoped_refptr<base::SingleThreadTaskRunner> GetTaskRunner(); 22 static scoped_refptr<base::SingleThreadTaskRunner> GetTaskRunner();
26 23
27 private: 24 private:
28 friend struct DefaultSingletonTraits<CmaMessageLoop>; 25 friend struct DefaultSingletonTraits<CmaMessageLoop>;
29 friend class Singleton<CmaMessageLoop>; 26 friend class Singleton<CmaMessageLoop>;
30 27
31 static CmaMessageLoop* GetInstance(); 28 static CmaMessageLoop* GetInstance();
32 29
33 CmaMessageLoop(); 30 CmaMessageLoop();
34 ~CmaMessageLoop(); 31 ~CmaMessageLoop();
35 32
36 scoped_ptr<base::Thread> thread_; 33 scoped_ptr<base::Thread> thread_;
37 34
38 DISALLOW_COPY_AND_ASSIGN(CmaMessageLoop); 35 DISALLOW_COPY_AND_ASSIGN(CmaMessageLoop);
39 }; 36 };
40 37
41 } // namespace media 38 } // namespace media
42 } // namespace chromecast 39 } // namespace chromecast
43 40
44 #endif // CHROMECAST_BROWSER_MEDIA_CMA_MESSAGE_LOOP_H_ 41 #endif // CHROMECAST_BROWSER_MEDIA_CMA_MESSAGE_LOOP_H_
OLDNEW
« no previous file with comments | « chromecast/browser/media/cma_message_filter_host.cc ('k') | chromecast/browser/media/cma_message_loop.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698