OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ | 5 #ifndef CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ |
6 #define CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ | 6 #define CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ |
7 | 7 |
8 #include <map> | 8 #include <map> |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
12 #include "base/compiler_specific.h" | 12 #include "base/compiler_specific.h" |
13 #include "base/memory/scoped_ptr.h" | 13 #include "base/memory/scoped_ptr.h" |
14 #include "base/process/process.h" | 14 #include "base/process/process.h" |
15 #include "base/scoped_native_library.h" | 15 #include "base/scoped_native_library.h" |
16 #include "build/build_config.h" | 16 #include "build/build_config.h" |
17 #include "content/child/child_thread.h" | 17 #include "content/child/child_thread_impl.h" |
18 #include "content/public/common/pepper_plugin_info.h" | 18 #include "content/public/common/pepper_plugin_info.h" |
19 #include "ppapi/c/pp_module.h" | 19 #include "ppapi/c/pp_module.h" |
20 #include "ppapi/c/trusted/ppp_broker.h" | 20 #include "ppapi/c/trusted/ppp_broker.h" |
21 #include "ppapi/proxy/connection.h" | 21 #include "ppapi/proxy/connection.h" |
22 #include "ppapi/proxy/plugin_dispatcher.h" | 22 #include "ppapi/proxy/plugin_dispatcher.h" |
23 #include "ppapi/proxy/plugin_globals.h" | 23 #include "ppapi/proxy/plugin_globals.h" |
24 #include "ppapi/proxy/plugin_proxy_delegate.h" | 24 #include "ppapi/proxy/plugin_proxy_delegate.h" |
25 | 25 |
26 #if defined(OS_WIN) | 26 #if defined(OS_WIN) |
27 #include "base/win/scoped_handle.h" | 27 #include "base/win/scoped_handle.h" |
28 #endif | 28 #endif |
29 | 29 |
30 namespace base { | 30 namespace base { |
31 class CommandLine; | 31 class CommandLine; |
32 class FilePath; | 32 class FilePath; |
33 } | 33 } |
34 | 34 |
35 namespace IPC { | 35 namespace IPC { |
36 struct ChannelHandle; | 36 struct ChannelHandle; |
37 } | 37 } |
38 | 38 |
39 namespace content { | 39 namespace content { |
40 | 40 |
41 class PpapiBlinkPlatformImpl; | 41 class PpapiBlinkPlatformImpl; |
42 | 42 |
43 class PpapiThread : public ChildThread, | 43 #if defined(COMPILER_MSVC) |
| 44 // See explanation for other RenderViewHostImpl which is the same issue. |
| 45 #pragma warning(push) |
| 46 #pragma warning(disable: 4250) |
| 47 #endif |
| 48 |
| 49 class PpapiThread : public ChildThreadImpl, |
44 public ppapi::proxy::PluginDispatcher::PluginDelegate, | 50 public ppapi::proxy::PluginDispatcher::PluginDelegate, |
45 public ppapi::proxy::PluginProxyDelegate { | 51 public ppapi::proxy::PluginProxyDelegate { |
46 public: | 52 public: |
47 PpapiThread(const base::CommandLine& command_line, bool is_broker); | 53 PpapiThread(const base::CommandLine& command_line, bool is_broker); |
48 ~PpapiThread() override; | 54 ~PpapiThread() override; |
49 void Shutdown() override; | 55 void Shutdown() override; |
50 | 56 |
51 private: | 57 private: |
52 // Make sure the enum list in tools/histogram/histograms.xml is updated with | 58 // Make sure the enum list in tools/histogram/histograms.xml is updated with |
53 // any change in this list. | 59 // any change in this list. |
(...skipping 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
151 scoped_ptr<PpapiBlinkPlatformImpl> blink_platform_impl_; | 157 scoped_ptr<PpapiBlinkPlatformImpl> blink_platform_impl_; |
152 | 158 |
153 #if defined(OS_WIN) | 159 #if defined(OS_WIN) |
154 // Caches the handle to the peer process if this is a broker. | 160 // Caches the handle to the peer process if this is a broker. |
155 base::win::ScopedHandle peer_handle_; | 161 base::win::ScopedHandle peer_handle_; |
156 #endif | 162 #endif |
157 | 163 |
158 DISALLOW_IMPLICIT_CONSTRUCTORS(PpapiThread); | 164 DISALLOW_IMPLICIT_CONSTRUCTORS(PpapiThread); |
159 }; | 165 }; |
160 | 166 |
| 167 #if defined(COMPILER_MSVC) |
| 168 #pragma warning(pop) |
| 169 #endif |
| 170 |
161 } // namespace content | 171 } // namespace content |
162 | 172 |
163 #endif // CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ | 173 #endif // CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ |
OLD | NEW |