| OLD | NEW |
| 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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 PPAPI_PROXY_PLUGIN_DISPATCHER_H_ | 5 #ifndef PPAPI_PROXY_PLUGIN_DISPATCHER_H_ |
| 6 #define PPAPI_PROXY_PLUGIN_DISPATCHER_H_ | 6 #define PPAPI_PROXY_PLUGIN_DISPATCHER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/process.h" | 10 #include "base/process.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 public: | 25 public: |
| 26 // Constructor for the plugin side. The init and shutdown functions will be | 26 // Constructor for the plugin side. The init and shutdown functions will be |
| 27 // will be automatically called when requested by the renderer side. The | 27 // will be automatically called when requested by the renderer side. The |
| 28 // module ID will be set upon receipt of the InitializeModule message. | 28 // module ID will be set upon receipt of the InitializeModule message. |
| 29 // | 29 // |
| 30 // You must call Dispatcher::InitWithChannel after the constructor. | 30 // You must call Dispatcher::InitWithChannel after the constructor. |
| 31 PluginDispatcher(base::ProcessHandle remote_process_handle, | 31 PluginDispatcher(base::ProcessHandle remote_process_handle, |
| 32 GetInterfaceFunc get_interface, | 32 GetInterfaceFunc get_interface, |
| 33 InitModuleFunc init_module, | 33 InitModuleFunc init_module, |
| 34 ShutdownModuleFunc shutdown_module); | 34 ShutdownModuleFunc shutdown_module); |
| 35 |
| 35 ~PluginDispatcher(); | 36 ~PluginDispatcher(); |
| 36 | 37 |
| 37 // Sets/gets the global dispatcher pointer. New code should use the | 38 // Sets/gets the global dispatcher pointer. New code should use the |
| 38 // GetForInstance version below, this is currently here as a stopgap while | 39 // GetForInstance version below, this is currently here as a stopgap while |
| 39 // the transition is being made. | 40 // the transition is being made. |
| 40 // | 41 // |
| 41 // TODO(brettw) remove this. | 42 // TODO(brettw) remove this. |
| 42 static PluginDispatcher* Get(); | 43 static PluginDispatcher* Get(); |
| 43 static void SetGlobal(PluginDispatcher* dispatcher); | 44 static void SetGlobal(PluginDispatcher* dispatcher); |
| 44 | 45 |
| (...skipping 21 matching lines...) Expand all Loading... |
| 66 InitModuleFunc init_module_; | 67 InitModuleFunc init_module_; |
| 67 ShutdownModuleFunc shutdown_module_; | 68 ShutdownModuleFunc shutdown_module_; |
| 68 | 69 |
| 69 DISALLOW_COPY_AND_ASSIGN(PluginDispatcher); | 70 DISALLOW_COPY_AND_ASSIGN(PluginDispatcher); |
| 70 }; | 71 }; |
| 71 | 72 |
| 72 } // namespace proxy | 73 } // namespace proxy |
| 73 } // namespace pp | 74 } // namespace pp |
| 74 | 75 |
| 75 #endif // PPAPI_PROXY_PLUGIN_DISPATCHER_H_ | 76 #endif // PPAPI_PROXY_PLUGIN_DISPATCHER_H_ |
| OLD | NEW |