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_RENDERER_RENDER_THREAD_IMPL_H_ | 5 #ifndef CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ |
6 #define CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ | 6 #define CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ |
7 | 7 |
8 #include <set> | 8 #include <set> |
9 #include <string> | 9 #include <string> |
10 #include <vector> | 10 #include <vector> |
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
148 int64 idle_notification_delay_in_ms) OVERRIDE; | 148 int64 idle_notification_delay_in_ms) OVERRIDE; |
149 virtual void ToggleWebKitSharedTimer(bool suspend) OVERRIDE; | 149 virtual void ToggleWebKitSharedTimer(bool suspend) OVERRIDE; |
150 virtual void UpdateHistograms(int sequence_number) OVERRIDE; | 150 virtual void UpdateHistograms(int sequence_number) OVERRIDE; |
151 virtual int PostTaskToAllWebWorkers(const base::Closure& closure) OVERRIDE; | 151 virtual int PostTaskToAllWebWorkers(const base::Closure& closure) OVERRIDE; |
152 virtual bool ResolveProxy(const GURL& url, std::string* proxy_list) OVERRIDE; | 152 virtual bool ResolveProxy(const GURL& url, std::string* proxy_list) OVERRIDE; |
153 #if defined(OS_WIN) | 153 #if defined(OS_WIN) |
154 virtual void PreCacheFont(const LOGFONT& log_font) OVERRIDE; | 154 virtual void PreCacheFont(const LOGFONT& log_font) OVERRIDE; |
155 virtual void ReleaseCachedFonts() OVERRIDE; | 155 virtual void ReleaseCachedFonts() OVERRIDE; |
156 #endif | 156 #endif |
157 | 157 |
158 // ChildThread: | |
159 virtual bool IsWebFrameValid(WebKit::WebFrame* frame) OVERRIDE; | |
160 | |
161 // GpuChannelHostFactory implementation: | 158 // GpuChannelHostFactory implementation: |
162 virtual bool IsMainThread() OVERRIDE; | 159 virtual bool IsMainThread() OVERRIDE; |
163 virtual base::MessageLoop* GetMainLoop() OVERRIDE; | 160 virtual base::MessageLoop* GetMainLoop() OVERRIDE; |
164 virtual scoped_refptr<base::MessageLoopProxy> GetIOLoopProxy() OVERRIDE; | 161 virtual scoped_refptr<base::MessageLoopProxy> GetIOLoopProxy() OVERRIDE; |
165 virtual base::WaitableEvent* GetShutDownEvent() OVERRIDE; | 162 virtual base::WaitableEvent* GetShutDownEvent() OVERRIDE; |
166 virtual scoped_ptr<base::SharedMemory> AllocateSharedMemory( | 163 virtual scoped_ptr<base::SharedMemory> AllocateSharedMemory( |
167 size_t size) OVERRIDE; | 164 size_t size) OVERRIDE; |
168 virtual int32 CreateViewCommandBuffer( | 165 virtual int32 CreateViewCommandBuffer( |
169 int32 surface_id, | 166 int32 surface_id, |
170 const GPUCreateCommandBufferConfig& init_params) OVERRIDE; | 167 const GPUCreateCommandBufferConfig& init_params) OVERRIDE; |
(...skipping 252 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
423 | 420 |
424 // The following flag is used to control layout test specific behavior. | 421 // The following flag is used to control layout test specific behavior. |
425 bool layout_test_mode_; | 422 bool layout_test_mode_; |
426 | 423 |
427 // Timer that periodically calls IdleHandler. | 424 // Timer that periodically calls IdleHandler. |
428 base::RepeatingTimer<RenderThreadImpl> idle_timer_; | 425 base::RepeatingTimer<RenderThreadImpl> idle_timer_; |
429 | 426 |
430 // The channel from the renderer process to the GPU process. | 427 // The channel from the renderer process to the GPU process. |
431 scoped_refptr<GpuChannelHost> gpu_channel_; | 428 scoped_refptr<GpuChannelHost> gpu_channel_; |
432 | 429 |
| 430 // Cache of variables that are needed on the compositor thread by |
| 431 // GpuChannelHostFactory methods. |
| 432 scoped_refptr<base::MessageLoopProxy> io_message_loop_proxy_; |
| 433 base::WaitableEvent* shutdown_event_; |
| 434 |
433 // A lazily initiated thread on which file operations are run. | 435 // A lazily initiated thread on which file operations are run. |
434 scoped_ptr<base::Thread> file_thread_; | 436 scoped_ptr<base::Thread> file_thread_; |
435 | 437 |
436 // May be null if overridden by ContentRendererClient. | 438 // May be null if overridden by ContentRendererClient. |
437 scoped_ptr<base::Thread> compositor_thread_; | 439 scoped_ptr<base::Thread> compositor_thread_; |
438 | 440 |
439 // Thread for running multimedia operations (e.g., video decoding). | 441 // Thread for running multimedia operations (e.g., video decoding). |
440 scoped_ptr<base::Thread> media_thread_; | 442 scoped_ptr<base::Thread> media_thread_; |
441 | 443 |
442 // Will point to appropriate MessageLoopProxy after initialization, | 444 // Will point to appropriate MessageLoopProxy after initialization, |
(...skipping 21 matching lines...) Expand all Loading... |
464 scoped_ptr<media::AudioHardwareConfig> audio_hardware_config_; | 466 scoped_ptr<media::AudioHardwareConfig> audio_hardware_config_; |
465 | 467 |
466 HistogramCustomizer histogram_customizer_; | 468 HistogramCustomizer histogram_customizer_; |
467 | 469 |
468 DISALLOW_COPY_AND_ASSIGN(RenderThreadImpl); | 470 DISALLOW_COPY_AND_ASSIGN(RenderThreadImpl); |
469 }; | 471 }; |
470 | 472 |
471 } // namespace content | 473 } // namespace content |
472 | 474 |
473 #endif // CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ | 475 #endif // CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ |
OLD | NEW |