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

Side by Side Diff: content/ppapi_plugin/ppapi_thread.h

Issue 8342016: Revert 106142 - Add a new globals object for PPAPI tracking information. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 2 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 | Annotate | Revision Log
« no previous file with comments | « chrome/renderer/chrome_ppb_pdf_impl.cc ('k') | ppapi/ppapi_proxy.gypi » ('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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #pragma once 7 #pragma once
8 8
9 #include <map> 9 #include <map>
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.h" 14 #include "base/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/common/child_thread.h" 17 #include "content/common/child_thread.h"
18 #include "ppapi/c/pp_module.h" 18 #include "ppapi/c/pp_module.h"
19 #include "ppapi/c/trusted/ppp_broker.h" 19 #include "ppapi/c/trusted/ppp_broker.h"
20 #include "ppapi/proxy/plugin_dispatcher.h" 20 #include "ppapi/proxy/plugin_dispatcher.h"
21 #include "ppapi/proxy/plugin_globals.h"
22 21
23 class FilePath; 22 class FilePath;
24 class PpapiWebKitThread; 23 class PpapiWebKitThread;
25 24
26 namespace IPC { 25 namespace IPC {
27 struct ChannelHandle; 26 struct ChannelHandle;
28 } 27 }
29 28
30 class PpapiThread : public ChildThread, 29 class PpapiThread : public ChildThread,
31 public ppapi::proxy::PluginDispatcher::PluginDelegate { 30 public ppapi::proxy::PluginDispatcher::PluginDelegate {
(...skipping 28 matching lines...) Expand all
60 // fills the given ChannelHandle with the information from the new channel. 59 // fills the given ChannelHandle with the information from the new channel.
61 bool SetupRendererChannel(base::ProcessHandle host_process_handle, 60 bool SetupRendererChannel(base::ProcessHandle host_process_handle,
62 int renderer_id, 61 int renderer_id,
63 IPC::ChannelHandle* handle); 62 IPC::ChannelHandle* handle);
64 63
65 // True if running in a broker process rather than a normal plugin process. 64 // True if running in a broker process rather than a normal plugin process.
66 bool is_broker_; 65 bool is_broker_;
67 66
68 base::ScopedNativeLibrary library_; 67 base::ScopedNativeLibrary library_;
69 68
70 // Global state tracking for the proxy.
71 ppapi::proxy::PluginGlobals plugin_globals_;
72
73 ppapi::proxy::Dispatcher::GetInterfaceFunc get_plugin_interface_; 69 ppapi::proxy::Dispatcher::GetInterfaceFunc get_plugin_interface_;
74 70
75 // Callback to call when a new instance connects to the broker. 71 // Callback to call when a new instance connects to the broker.
76 // Used only when is_broker_. 72 // Used only when is_broker_.
77 PP_ConnectInstance_Func connect_instance_func_; 73 PP_ConnectInstance_Func connect_instance_func_;
78 74
79 // Local concept of the module ID. Some functions take this. It's necessary 75 // Local concept of the module ID. Some functions take this. It's necessary
80 // for the in-process PPAPI to handle this properly, but for proxied it's 76 // for the in-process PPAPI to handle this properly, but for proxied it's
81 // unnecessary. The proxy talking to multiple renderers means that each 77 // unnecessary. The proxy talking to multiple renderers means that each
82 // renderer has a different idea of what the module ID is for this plugin. 78 // renderer has a different idea of what the module ID is for this plugin.
(...skipping 10 matching lines...) Expand all
93 scoped_ptr<PpapiWebKitThread> webkit_thread_; 89 scoped_ptr<PpapiWebKitThread> webkit_thread_;
94 90
95 // The PluginDispatcher instances contained in the map are not owned by it. 91 // The PluginDispatcher instances contained in the map are not owned by it.
96 std::map<uint32, ppapi::proxy::PluginDispatcher*> plugin_dispatchers_; 92 std::map<uint32, ppapi::proxy::PluginDispatcher*> plugin_dispatchers_;
97 uint32 next_plugin_dispatcher_id_; 93 uint32 next_plugin_dispatcher_id_;
98 94
99 DISALLOW_IMPLICIT_CONSTRUCTORS(PpapiThread); 95 DISALLOW_IMPLICIT_CONSTRUCTORS(PpapiThread);
100 }; 96 };
101 97
102 #endif // CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_ 98 #endif // CONTENT_PPAPI_PLUGIN_PPAPI_THREAD_H_
OLDNEW
« no previous file with comments | « chrome/renderer/chrome_ppb_pdf_impl.cc ('k') | ppapi/ppapi_proxy.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698