Chromium Code Reviews| 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 416 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 427 RenderThreadImpl(const InProcessChildThreadParams& params, | 427 RenderThreadImpl(const InProcessChildThreadParams& params, |
| 428 scoped_ptr<scheduler::RendererScheduler> scheduler); | 428 scoped_ptr<scheduler::RendererScheduler> scheduler); |
| 429 RenderThreadImpl(scoped_ptr<base::MessageLoop> main_message_loop, | 429 RenderThreadImpl(scoped_ptr<base::MessageLoop> main_message_loop, |
| 430 scoped_ptr<scheduler::RendererScheduler> scheduler); | 430 scoped_ptr<scheduler::RendererScheduler> scheduler); |
| 431 virtual void SetResourceDispatchTaskQueue( | 431 virtual void SetResourceDispatchTaskQueue( |
| 432 const scoped_refptr<base::SingleThreadTaskRunner>& resource_task_queue); | 432 const scoped_refptr<base::SingleThreadTaskRunner>& resource_task_queue); |
| 433 | 433 |
| 434 private: | 434 private: |
| 435 // ChildThread | 435 // ChildThread |
| 436 bool OnControlMessageReceived(const IPC::Message& msg) override; | 436 bool OnControlMessageReceived(const IPC::Message& msg) override; |
| 437 void OnProcessBackgrounded(bool backgrounded) override; | |
| 437 | 438 |
| 438 // GpuChannelHostFactory implementation: | 439 // GpuChannelHostFactory implementation: |
| 439 bool IsMainThread() override; | 440 bool IsMainThread() override; |
| 440 scoped_refptr<base::SingleThreadTaskRunner> GetIOThreadTaskRunner() override; | 441 scoped_refptr<base::SingleThreadTaskRunner> GetIOThreadTaskRunner() override; |
| 441 scoped_ptr<base::SharedMemory> AllocateSharedMemory(size_t size) override; | 442 scoped_ptr<base::SharedMemory> AllocateSharedMemory(size_t size) override; |
| 442 CreateCommandBufferResult CreateViewCommandBuffer( | 443 CreateCommandBufferResult CreateViewCommandBuffer( |
| 443 int32 surface_id, | 444 int32 surface_id, |
| 444 const GPUCreateCommandBufferConfig& init_params, | 445 const GPUCreateCommandBufferConfig& init_params, |
| 445 int32 route_id) override; | 446 int32 route_id) override; |
| 446 | 447 |
| (...skipping 22 matching lines...) Expand all Loading... | |
| 469 #endif | 470 #endif |
| 470 #if defined(OS_MACOSX) | 471 #if defined(OS_MACOSX) |
| 471 void OnUpdateScrollbarTheme( | 472 void OnUpdateScrollbarTheme( |
| 472 const ViewMsg_UpdateScrollbarTheme_Params& params); | 473 const ViewMsg_UpdateScrollbarTheme_Params& params); |
| 473 #endif | 474 #endif |
| 474 void OnCreateNewSharedWorker( | 475 void OnCreateNewSharedWorker( |
| 475 const WorkerProcessMsg_CreateWorker_Params& params); | 476 const WorkerProcessMsg_CreateWorker_Params& params); |
| 476 bool RendererIsHidden() const; | 477 bool RendererIsHidden() const; |
| 477 void OnRendererHidden(); | 478 void OnRendererHidden(); |
| 478 void OnRendererVisible(); | 479 void OnRendererVisible(); |
| 480 void OnSetWebKitSharedTimersSuspendedAfterHidden(bool suspend); | |
|
Sami
2015/08/28 14:15:01
I guess this isn't needed?
jdduke (slow)
2015/08/31 18:36:08
Done.
| |
| 479 | 481 |
| 480 void ReleaseFreeMemory(); | 482 void ReleaseFreeMemory(); |
| 481 | 483 |
| 482 scoped_ptr<WebGraphicsContext3DCommandBufferImpl> CreateOffscreenContext3d(); | 484 scoped_ptr<WebGraphicsContext3DCommandBufferImpl> CreateOffscreenContext3d(); |
| 483 | 485 |
| 484 // These objects live solely on the render thread. | 486 // These objects live solely on the render thread. |
| 485 scoped_ptr<AppCacheDispatcher> appcache_dispatcher_; | 487 scoped_ptr<AppCacheDispatcher> appcache_dispatcher_; |
| 486 scoped_ptr<DomStorageDispatcher> dom_storage_dispatcher_; | 488 scoped_ptr<DomStorageDispatcher> dom_storage_dispatcher_; |
| 487 scoped_ptr<IndexedDBDispatcher> main_thread_indexed_db_dispatcher_; | 489 scoped_ptr<IndexedDBDispatcher> main_thread_indexed_db_dispatcher_; |
| 488 scoped_ptr<scheduler::RendererScheduler> renderer_scheduler_; | 490 scoped_ptr<scheduler::RendererScheduler> renderer_scheduler_; |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 533 // The count of hidden RenderWidgets running through this thread. | 535 // The count of hidden RenderWidgets running through this thread. |
| 534 int hidden_widget_count_; | 536 int hidden_widget_count_; |
| 535 | 537 |
| 536 // The current value of the idle notification timer delay. | 538 // The current value of the idle notification timer delay. |
| 537 int64 idle_notification_delay_in_ms_; | 539 int64 idle_notification_delay_in_ms_; |
| 538 | 540 |
| 539 // The number of idle handler calls that skip sending idle notifications. | 541 // The number of idle handler calls that skip sending idle notifications. |
| 540 int idle_notifications_to_skip_; | 542 int idle_notifications_to_skip_; |
| 541 | 543 |
| 542 bool notify_webkit_of_modal_loop_; | 544 bool notify_webkit_of_modal_loop_; |
| 545 | |
| 543 bool webkit_shared_timer_suspended_; | 546 bool webkit_shared_timer_suspended_; |
| 544 | 547 |
| 545 // The following flag is used to control layout test specific behavior. | 548 // The following flag is used to control layout test specific behavior. |
| 546 bool layout_test_mode_; | 549 bool layout_test_mode_; |
| 547 | 550 |
| 548 // Timer that periodically calls IdleHandler. | 551 // Timer that periodically calls IdleHandler. |
| 549 base::RepeatingTimer<RenderThreadImpl> idle_timer_; | 552 base::RepeatingTimer<RenderThreadImpl> idle_timer_; |
| 550 | 553 |
| 551 // The channel from the renderer process to the GPU process. | 554 // The channel from the renderer process to the GPU process. |
| 552 scoped_refptr<GpuChannelHost> gpu_channel_; | 555 scoped_refptr<GpuChannelHost> gpu_channel_; |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 656 DISALLOW_COPY_AND_ASSIGN(RenderThreadImpl); | 659 DISALLOW_COPY_AND_ASSIGN(RenderThreadImpl); |
| 657 }; | 660 }; |
| 658 | 661 |
| 659 #if defined(COMPILER_MSVC) | 662 #if defined(COMPILER_MSVC) |
| 660 #pragma warning(pop) | 663 #pragma warning(pop) |
| 661 #endif | 664 #endif |
| 662 | 665 |
| 663 } // namespace content | 666 } // namespace content |
| 664 | 667 |
| 665 #endif // CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ | 668 #endif // CONTENT_RENDERER_RENDER_THREAD_IMPL_H_ |
| OLD | NEW |