| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_SCHEDULER_RENDERER_RENDERER_SCHEDULER_IMPL_H_ | 5 #ifndef COMPONENTS_SCHEDULER_RENDERER_RENDERER_SCHEDULER_IMPL_H_ |
| 6 #define COMPONENTS_SCHEDULER_RENDERER_RENDERER_SCHEDULER_IMPL_H_ | 6 #define COMPONENTS_SCHEDULER_RENDERER_RENDERER_SCHEDULER_IMPL_H_ |
| 7 | 7 |
| 8 #include "base/atomicops.h" | 8 #include "base/atomicops.h" |
| 9 #include "base/synchronization/lock.h" | 9 #include "base/synchronization/lock.h" |
| 10 #include "components/scheduler/child/idle_helper.h" | 10 #include "components/scheduler/child/idle_helper.h" |
| (...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 195 scoped_refptr<base::SingleThreadTaskRunner> timer_task_runner_; | 195 scoped_refptr<base::SingleThreadTaskRunner> timer_task_runner_; |
| 196 | 196 |
| 197 base::Closure update_policy_closure_; | 197 base::Closure update_policy_closure_; |
| 198 DeadlineTaskRunner delayed_update_policy_runner_; | 198 DeadlineTaskRunner delayed_update_policy_runner_; |
| 199 CancelableClosureHolder end_renderer_hidden_idle_period_closure_; | 199 CancelableClosureHolder end_renderer_hidden_idle_period_closure_; |
| 200 | 200 |
| 201 // Don't access current_policy_ directly, instead use SchedulerPolicy(). | 201 // Don't access current_policy_ directly, instead use SchedulerPolicy(). |
| 202 Policy current_policy_; | 202 Policy current_policy_; |
| 203 base::TimeTicks current_policy_expiration_time_; | 203 base::TimeTicks current_policy_expiration_time_; |
| 204 bool renderer_hidden_; | 204 bool renderer_hidden_; |
| 205 bool was_shutdown_; |
| 205 | 206 |
| 206 base::TimeTicks estimated_next_frame_begin_; | 207 base::TimeTicks estimated_next_frame_begin_; |
| 207 | 208 |
| 208 // The incoming_signals_lock_ mutex protects access to all variables in the | 209 // The incoming_signals_lock_ mutex protects access to all variables in the |
| 209 // (contiguous) block below. | 210 // (contiguous) block below. |
| 210 mutable base::Lock incoming_signals_lock_; | 211 mutable base::Lock incoming_signals_lock_; |
| 211 base::TimeTicks last_input_receipt_time_on_compositor_; | 212 base::TimeTicks last_input_receipt_time_on_compositor_; |
| 212 base::TimeTicks last_input_process_time_on_main_; | 213 base::TimeTicks last_input_process_time_on_main_; |
| 213 blink::WebInputEvent::Type last_input_type_; | 214 blink::WebInputEvent::Type last_input_type_; |
| 214 InputStreamState input_stream_state_; | 215 InputStreamState input_stream_state_; |
| 215 PollableNeedsUpdateFlag policy_may_need_update_; | 216 PollableNeedsUpdateFlag policy_may_need_update_; |
| 216 int timer_queue_suspend_count_; // TIMER_TASK_QUEUE suspended if non-zero. | 217 int timer_queue_suspend_count_; // TIMER_TASK_QUEUE suspended if non-zero. |
| 217 | 218 |
| 218 base::WeakPtrFactory<RendererSchedulerImpl> weak_factory_; | 219 base::WeakPtrFactory<RendererSchedulerImpl> weak_factory_; |
| 219 | 220 |
| 220 DISALLOW_COPY_AND_ASSIGN(RendererSchedulerImpl); | 221 DISALLOW_COPY_AND_ASSIGN(RendererSchedulerImpl); |
| 221 }; | 222 }; |
| 222 | 223 |
| 223 } // namespace scheduler | 224 } // namespace scheduler |
| 224 | 225 |
| 225 #endif // COMPONENTS_SCHEDULER_RENDERER_RENDERER_SCHEDULER_IMPL_H_ | 226 #endif // COMPONENTS_SCHEDULER_RENDERER_RENDERER_SCHEDULER_IMPL_H_ |
| OLD | NEW |