| 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 CHROME_PPAPI_PLUGIN_PPAPI_THREAD_H_ | 5 #ifndef CHROME_PPAPI_PLUGIN_PPAPI_THREAD_H_ |
| 6 #define CHROME_PPAPI_PLUGIN_PPAPI_THREAD_H_ | 6 #define CHROME_PPAPI_PLUGIN_PPAPI_THREAD_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/process.h" | 10 #include "base/process.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 } | 25 } |
| 26 } | 26 } |
| 27 | 27 |
| 28 class PpapiThread : public ChildThread { | 28 class PpapiThread : public ChildThread { |
| 29 public: | 29 public: |
| 30 PpapiThread(); | 30 PpapiThread(); |
| 31 ~PpapiThread(); | 31 ~PpapiThread(); |
| 32 | 32 |
| 33 private: | 33 private: |
| 34 // ChildThread overrides. | 34 // ChildThread overrides. |
| 35 virtual void OnMessageReceived(const IPC::Message& msg); | 35 virtual bool OnMessageReceived(const IPC::Message& msg); |
| 36 | 36 |
| 37 // Message handlers. | 37 // Message handlers. |
| 38 void OnMsgLoadPlugin(base::ProcessHandle renderer_handle, | 38 void OnMsgLoadPlugin(base::ProcessHandle renderer_handle, |
| 39 const FilePath& path, | 39 const FilePath& path, |
| 40 int renderer_id); | 40 int renderer_id); |
| 41 | 41 |
| 42 bool LoadPluginLib(base::ProcessHandle host_process_handle, | 42 bool LoadPluginLib(base::ProcessHandle host_process_handle, |
| 43 const FilePath& path); | 43 const FilePath& path); |
| 44 | 44 |
| 45 // Sets up the channel to the given renderer. On success, returns true and | 45 // Sets up the channel to the given renderer. On success, returns true and |
| (...skipping 16 matching lines...) Expand all Loading... |
| 62 // FD for the renderer end of the socket. It is closed when the IPC layer | 62 // FD for the renderer end of the socket. It is closed when the IPC layer |
| 63 // indicates that the channel is connected, proving that the renderer has | 63 // indicates that the channel is connected, proving that the renderer has |
| 64 // access to its side of the socket. | 64 // access to its side of the socket. |
| 65 int renderer_fd_; | 65 int renderer_fd_; |
| 66 #endif | 66 #endif |
| 67 | 67 |
| 68 DISALLOW_COPY_AND_ASSIGN(PpapiThread); | 68 DISALLOW_COPY_AND_ASSIGN(PpapiThread); |
| 69 }; | 69 }; |
| 70 | 70 |
| 71 #endif // CHROME_PPAPI_PLUGIN_PPAPI_THREAD_H_ | 71 #endif // CHROME_PPAPI_PLUGIN_PPAPI_THREAD_H_ |
| OLD | NEW |