| 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_PUBLIC_RENDERER_RENDER_THREAD_H_ | 5 #ifndef CONTENT_PUBLIC_RENDERER_RENDER_THREAD_H_ |
| 6 #define CONTENT_PUBLIC_RENDERER_RENDER_THREAD_H_ | 6 #define CONTENT_PUBLIC_RENDERER_RENDER_THREAD_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/basictypes.h" |
| 9 #include "base/callback.h" | 9 #include "base/callback.h" |
| 10 #include "base/memory/shared_memory.h" | 10 #include "base/memory/shared_memory.h" |
| (...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 43 | 43 |
| 44 class CONTENT_EXPORT RenderThread : virtual public ChildThread { | 44 class CONTENT_EXPORT RenderThread : virtual public ChildThread { |
| 45 public: | 45 public: |
| 46 // Returns the one render thread for this process. Note that this can only | 46 // Returns the one render thread for this process. Note that this can only |
| 47 // be accessed when running on the render thread itself. | 47 // be accessed when running on the render thread itself. |
| 48 static RenderThread* Get(); | 48 static RenderThread* Get(); |
| 49 | 49 |
| 50 RenderThread(); | 50 RenderThread(); |
| 51 ~RenderThread() override; | 51 ~RenderThread() override; |
| 52 | 52 |
| 53 virtual scoped_refptr<base::SingleThreadTaskRunner> GetTaskRunner() = 0; | |
| 54 virtual IPC::SyncChannel* GetChannel() = 0; | 53 virtual IPC::SyncChannel* GetChannel() = 0; |
| 55 virtual std::string GetLocale() = 0; | 54 virtual std::string GetLocale() = 0; |
| 56 virtual IPC::SyncMessageFilter* GetSyncMessageFilter() = 0; | 55 virtual IPC::SyncMessageFilter* GetSyncMessageFilter() = 0; |
| 57 virtual scoped_refptr<base::MessageLoopProxy> GetIOMessageLoopProxy() = 0; | 56 virtual scoped_refptr<base::MessageLoopProxy> GetIOMessageLoopProxy() = 0; |
| 58 | 57 |
| 59 // Called to add or remove a listener for a particular message routing ID. | 58 // Called to add or remove a listener for a particular message routing ID. |
| 60 // These methods normally get delegated to a MessageRouter. | 59 // These methods normally get delegated to a MessageRouter. |
| 61 virtual void AddRoute(int32 routing_id, IPC::Listener* listener) = 0; | 60 virtual void AddRoute(int32 routing_id, IPC::Listener* listener) = 0; |
| 62 virtual void RemoveRoute(int32 routing_id) = 0; | 61 virtual void RemoveRoute(int32 routing_id) = 0; |
| 63 virtual int GenerateRoutingID() = 0; | 62 virtual int GenerateRoutingID() = 0; |
| (...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 131 // Gets the shutdown event for the process. | 130 // Gets the shutdown event for the process. |
| 132 virtual base::WaitableEvent* GetShutdownEvent() = 0; | 131 virtual base::WaitableEvent* GetShutdownEvent() = 0; |
| 133 | 132 |
| 134 // Returns the ServiceRegistry for this thread. | 133 // Returns the ServiceRegistry for this thread. |
| 135 virtual ServiceRegistry* GetServiceRegistry() = 0; | 134 virtual ServiceRegistry* GetServiceRegistry() = 0; |
| 136 }; | 135 }; |
| 137 | 136 |
| 138 } // namespace content | 137 } // namespace content |
| 139 | 138 |
| 140 #endif // CONTENT_PUBLIC_RENDERER_RENDER_THREAD_H_ | 139 #endif // CONTENT_PUBLIC_RENDERER_RENDER_THREAD_H_ |
| OLD | NEW |