| 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_RENDERER_RENDER_THREAD_H_ | 5 #ifndef CHROME_RENDERER_RENDER_THREAD_H_ |
| 6 #define CHROME_RENDERER_RENDER_THREAD_H_ | 6 #define CHROME_RENDERER_RENDER_THREAD_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 void SetCacheMode(bool enabled); | 165 void SetCacheMode(bool enabled); |
| 166 | 166 |
| 167 // Update the list of active extensions that will be reported when we crash. | 167 // Update the list of active extensions that will be reported when we crash. |
| 168 void UpdateActiveExtensions(); | 168 void UpdateActiveExtensions(); |
| 169 | 169 |
| 170 // Asynchronously establish a channel to the GPU plugin if not previously | 170 // Asynchronously establish a channel to the GPU plugin if not previously |
| 171 // established or if it has been lost (for example if the GPU plugin crashed). | 171 // established or if it has been lost (for example if the GPU plugin crashed). |
| 172 // Use GetGpuChannel() to determine when the channel is ready for use. | 172 // Use GetGpuChannel() to determine when the channel is ready for use. |
| 173 void EstablishGpuChannel(); | 173 void EstablishGpuChannel(); |
| 174 | 174 |
| 175 // Synchronously establish a channel to the GPU plugin if not previously |
| 176 // established or if it has been lost (for example if the GPU plugin crashed). |
| 177 // If there is a pending asynchronous request, it will be completed by the |
| 178 // time this routine returns. |
| 179 GpuChannelHost* EstablishGpuChannelSync(); |
| 180 |
| 175 // Get the GPU channel. Returns NULL if the channel is not established or | 181 // Get the GPU channel. Returns NULL if the channel is not established or |
| 176 // has been lost. | 182 // has been lost. |
| 177 GpuChannelHost* GetGpuChannel(); | 183 GpuChannelHost* GetGpuChannel(); |
| 178 | 184 |
| 179 private: | 185 private: |
| 180 virtual void OnControlMessageReceived(const IPC::Message& msg); | 186 virtual void OnControlMessageReceived(const IPC::Message& msg); |
| 181 | 187 |
| 182 void Init(); | 188 void Init(); |
| 183 | 189 |
| 184 void OnUpdateVisitedLinks(base::SharedMemoryHandle table); | 190 void OnUpdateVisitedLinks(base::SharedMemoryHandle table); |
| (...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 301 // not idle, to ensure that IdleHandle gets called eventually. | 307 // not idle, to ensure that IdleHandle gets called eventually. |
| 302 base::RepeatingTimer<RenderThread> forced_idle_timer_; | 308 base::RepeatingTimer<RenderThread> forced_idle_timer_; |
| 303 | 309 |
| 304 // The channel from the renderer process to the GPU process. | 310 // The channel from the renderer process to the GPU process. |
| 305 scoped_refptr<GpuChannelHost> gpu_channel_; | 311 scoped_refptr<GpuChannelHost> gpu_channel_; |
| 306 | 312 |
| 307 DISALLOW_COPY_AND_ASSIGN(RenderThread); | 313 DISALLOW_COPY_AND_ASSIGN(RenderThread); |
| 308 }; | 314 }; |
| 309 | 315 |
| 310 #endif // CHROME_RENDERER_RENDER_THREAD_H_ | 316 #endif // CHROME_RENDERER_RENDER_THREAD_H_ |
| OLD | NEW |