OLD | NEW |
---|---|
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_IMPL_H_ | 5 #ifndef CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_IMPL_H_ |
6 #define CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_IMPL_H_ | 6 #define CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_IMPL_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
11 | 11 |
12 #include "base/containers/hash_tables.h" | 12 #include "base/containers/hash_tables.h" |
13 #include "base/containers/scoped_ptr_hash_map.h" | 13 #include "base/containers/scoped_ptr_hash_map.h" |
14 #include "base/macros.h" | 14 #include "base/macros.h" |
15 #include "base/memory/ref_counted.h" | 15 #include "base/memory/ref_counted.h" |
16 #include "base/memory/scoped_ptr.h" | 16 #include "base/memory/scoped_ptr.h" |
17 #include "base/memory/weak_ptr.h" | 17 #include "base/memory/weak_ptr.h" |
18 #include "base/observer_list.h" | 18 #include "base/observer_list.h" |
19 #include "base/thread_task_runner_handle.h" | 19 #include "base/thread_task_runner_handle.h" |
20 #include "base/threading/thread_checker.h" | 20 #include "base/threading/thread_checker.h" |
21 #include "chrome/browser/media/router/issue.h" | 21 #include "chrome/browser/media/router/issue.h" |
22 #include "chrome/browser/media/router/issue_manager.h" | 22 #include "chrome/browser/media/router/issue_manager.h" |
23 #include "chrome/browser/media/router/media_router.h" | 23 #include "chrome/browser/media/router/media_router.h" |
24 #include "chrome/browser/media/router/media_router.mojom.h" | 24 #include "chrome/browser/media/router/media_router.mojom.h" |
25 | 25 |
26 class TestMediaRouterAction; | |
27 | |
26 namespace content { | 28 namespace content { |
27 class BrowserContext; | 29 class BrowserContext; |
28 } | 30 } |
29 | 31 |
30 namespace extensions { | 32 namespace extensions { |
31 class EventPageTracker; | 33 class EventPageTracker; |
32 } | 34 } |
33 | 35 |
34 namespace media_router { | 36 namespace media_router { |
35 | 37 |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
92 return media_route_provider_extension_id_; | 94 return media_route_provider_extension_id_; |
93 } | 95 } |
94 | 96 |
95 void set_instance_id_for_test(const std::string& instance_id) { | 97 void set_instance_id_for_test(const std::string& instance_id) { |
96 instance_id_ = instance_id; | 98 instance_id_ = instance_id; |
97 } | 99 } |
98 | 100 |
99 private: | 101 private: |
100 friend class MediaRouterFactory; | 102 friend class MediaRouterFactory; |
101 friend class MediaRouterMojoTest; | 103 friend class MediaRouterMojoTest; |
104 friend class ::TestMediaRouterAction; | |
Kevin M
2015/08/03 17:15:37
Is the :: needed here?
apacible
2015/08/03 20:47:22
Yes, this is to specify TestMediaRouterAction isn'
| |
102 | 105 |
103 FRIEND_TEST_ALL_PREFIXES(MediaRouterMojoExtensionTest, | 106 FRIEND_TEST_ALL_PREFIXES(MediaRouterMojoExtensionTest, |
104 DeferredBindingAndSuspension); | 107 DeferredBindingAndSuspension); |
105 | 108 |
106 // Standard constructor, used by | 109 // Standard constructor, used by |
107 // MediaRouterMojoImplFactory::GetApiForBrowserContext. | 110 // MediaRouterMojoImplFactory::GetApiForBrowserContext. |
108 explicit MediaRouterMojoImpl( | 111 explicit MediaRouterMojoImpl( |
109 extensions::EventPageTracker* event_page_tracker); | 112 extensions::EventPageTracker* event_page_tracker); |
110 | 113 |
111 // Binds |this| to a Mojo interface request, so that clients can acquire a | 114 // Binds |this| to a Mojo interface request, so that clients can acquire a |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
209 std::string instance_id_; | 212 std::string instance_id_; |
210 | 213 |
211 base::ThreadChecker thread_checker_; | 214 base::ThreadChecker thread_checker_; |
212 | 215 |
213 DISALLOW_COPY_AND_ASSIGN(MediaRouterMojoImpl); | 216 DISALLOW_COPY_AND_ASSIGN(MediaRouterMojoImpl); |
214 }; | 217 }; |
215 | 218 |
216 } // namespace media_router | 219 } // namespace media_router |
217 | 220 |
218 #endif // CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_IMPL_H_ | 221 #endif // CHROME_BROWSER_MEDIA_ROUTER_MEDIA_ROUTER_MOJO_IMPL_H_ |
OLD | NEW |