OLD | NEW |
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_RENDERER_CAST_RENDER_PROCESS_OBSERVER_H_ | 5 #ifndef CHROMECAST_RENDERER_CAST_RENDER_PROCESS_OBSERVER_H_ |
6 #define CHROMECAST_RENDERER_CAST_RENDER_PROCESS_OBSERVER_H_ | 6 #define CHROMECAST_RENDERER_CAST_RENDER_PROCESS_OBSERVER_H_ |
7 | 7 |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include "base/macros.h" | 10 #include "base/macros.h" |
11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
12 #include "content/public/renderer/render_process_observer.h" | 12 #include "content/public/renderer/render_process_observer.h" |
13 | 13 |
14 namespace IPC { | 14 namespace IPC { |
15 class MessageFilter; | 15 class MessageFilter; |
16 } | 16 } |
17 | 17 |
18 namespace chromecast { | 18 namespace chromecast { |
| 19 class CapabilitiesMessageFilter; |
19 namespace media { | 20 namespace media { |
20 class CmaMessageFilterProxy; | 21 class CmaMessageFilterProxy; |
21 } | 22 } |
22 | 23 |
23 namespace shell { | 24 namespace shell { |
24 | 25 |
25 class CastRenderProcessObserver : public content::RenderProcessObserver { | 26 class CastRenderProcessObserver : public content::RenderProcessObserver { |
26 public: | 27 public: |
27 CastRenderProcessObserver( | 28 CastRenderProcessObserver( |
28 const std::vector<scoped_refptr<IPC::MessageFilter>>& | 29 const std::vector<scoped_refptr<IPC::MessageFilter>>& |
29 platform_message_filters); | 30 platform_message_filters); |
30 ~CastRenderProcessObserver() override; | 31 ~CastRenderProcessObserver() override; |
31 | 32 |
32 private: | 33 private: |
33 // content::RenderProcessObserver implementation: | 34 // content::RenderProcessObserver implementation: |
34 void OnRenderProcessShutdown() override; | 35 void OnRenderProcessShutdown() override; |
35 | 36 |
36 void CreateCustomFilters(); | 37 void CreateCustomFilters(); |
37 | 38 |
38 #if !defined(OS_ANDROID) | 39 #if !defined(OS_ANDROID) |
39 scoped_refptr<media::CmaMessageFilterProxy> cma_message_filter_proxy_; | 40 scoped_refptr<media::CmaMessageFilterProxy> cma_message_filter_proxy_; |
40 #endif // !defined(OS_ANDROID) | 41 #endif // !defined(OS_ANDROID) |
| 42 scoped_refptr<CapabilitiesMessageFilter> capabilities_message_filter_; |
41 std::vector<scoped_refptr<IPC::MessageFilter>> platform_message_filters_; | 43 std::vector<scoped_refptr<IPC::MessageFilter>> platform_message_filters_; |
42 | 44 |
43 DISALLOW_COPY_AND_ASSIGN(CastRenderProcessObserver); | 45 DISALLOW_COPY_AND_ASSIGN(CastRenderProcessObserver); |
44 }; | 46 }; |
45 | 47 |
46 } // namespace shell | 48 } // namespace shell |
47 } // namespace chromecast | 49 } // namespace chromecast |
48 | 50 |
49 #endif // CHROMECAST_RENDERER_CAST_RENDER_PROCESS_OBSERVER_H_ | 51 #endif // CHROMECAST_RENDERER_CAST_RENDER_PROCESS_OBSERVER_H_ |
OLD | NEW |