| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WEB_SCHEDULER_IMPL_H_ | 5 #ifndef THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WEB_SCHEDULER_IMPL_H_ |
| 6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WEB_SCHEDULER_IMPL_H_ | 6 #define THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WEB_SCHEDULER_IMPL_H_ |
| 7 | 7 |
| 8 #include <memory> | 8 #include <memory> |
| 9 | 9 |
| 10 #include "base/macros.h" | 10 #include "base/macros.h" |
| 11 #include "base/memory/ref_counted.h" | 11 #include "base/memory/ref_counted.h" |
| 12 #include "base/time/time.h" | 12 #include "base/time/time.h" |
| 13 #include "platform/PlatformExport.h" |
| 13 #include "platform/scheduler/base/task_queue.h" | 14 #include "platform/scheduler/base/task_queue.h" |
| 14 #include "platform/scheduler/child/web_scheduler.h" | 15 #include "platform/scheduler/child/web_scheduler.h" |
| 15 #include "public/platform/WebCommon.h" | |
| 16 #include "public/platform/WebThread.h" | 16 #include "public/platform/WebThread.h" |
| 17 | 17 |
| 18 namespace blink { | 18 namespace blink { |
| 19 namespace scheduler { | 19 namespace scheduler { |
| 20 | 20 |
| 21 class ChildScheduler; | 21 class ChildScheduler; |
| 22 class SingleThreadIdleTaskRunner; | 22 class SingleThreadIdleTaskRunner; |
| 23 class WebTaskRunnerImpl; | 23 class WebTaskRunnerImpl; |
| 24 | 24 |
| 25 class BLINK_PLATFORM_EXPORT WebSchedulerImpl : public WebScheduler { | 25 class PLATFORM_EXPORT WebSchedulerImpl : public WebScheduler { |
| 26 public: | 26 public: |
| 27 WebSchedulerImpl(ChildScheduler* child_scheduler, | 27 WebSchedulerImpl(ChildScheduler* child_scheduler, |
| 28 scoped_refptr<SingleThreadIdleTaskRunner> idle_task_runner, | 28 scoped_refptr<SingleThreadIdleTaskRunner> idle_task_runner, |
| 29 scoped_refptr<TaskQueue> loading_task_runner, | 29 scoped_refptr<TaskQueue> loading_task_runner, |
| 30 scoped_refptr<TaskQueue> timer_task_runner); | 30 scoped_refptr<TaskQueue> timer_task_runner); |
| 31 ~WebSchedulerImpl() override; | 31 ~WebSchedulerImpl() override; |
| 32 | 32 |
| 33 // WebScheduler implementation: | 33 // WebScheduler implementation: |
| 34 void Shutdown() override; | 34 void Shutdown() override; |
| 35 bool ShouldYieldForHighPriorityWork() override; | 35 bool ShouldYieldForHighPriorityWork() override; |
| (...skipping 23 matching lines...) Expand all Loading... |
| 59 RefPtr<WebTaskRunnerImpl> loading_web_task_runner_; | 59 RefPtr<WebTaskRunnerImpl> loading_web_task_runner_; |
| 60 RefPtr<WebTaskRunnerImpl> timer_web_task_runner_; | 60 RefPtr<WebTaskRunnerImpl> timer_web_task_runner_; |
| 61 | 61 |
| 62 DISALLOW_COPY_AND_ASSIGN(WebSchedulerImpl); | 62 DISALLOW_COPY_AND_ASSIGN(WebSchedulerImpl); |
| 63 }; | 63 }; |
| 64 | 64 |
| 65 } // namespace scheduler | 65 } // namespace scheduler |
| 66 } // namespace blink | 66 } // namespace blink |
| 67 | 67 |
| 68 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WEB_SCHEDULER_IMPL
_H_ | 68 #endif // THIRD_PARTY_WEBKIT_SOURCE_PLATFORM_SCHEDULER_CHILD_WEB_SCHEDULER_IMPL
_H_ |
| OLD | NEW |