summaryrefslogtreecommitdiffstats
path: root/cc/test
diff options
context:
space:
mode:
authorenne <enne@chromium.org>2016-03-18 11:22:43 -0700
committerCommit bot <commit-bot@chromium.org>2016-03-18 18:24:17 +0000
commit0ec0805af79680611fbfbc5d0e825eb18039cf9d (patch)
tree42ec1ec9be29c82a7a3168813f9fa53c8c8f6dac /cc/test
parentc987fed5acb7cad3d489ebe7c31fd5a6bd265823 (diff)
downloadchromium_src-0ec0805af79680611fbfbc5d0e825eb18039cf9d.zip
chromium_src-0ec0805af79680611fbfbc5d0e825eb18039cf9d.tar.gz
chromium_src-0ec0805af79680611fbfbc5d0e825eb18039cf9d.tar.bz2
Allow null begin frame sources in cc::Scheduler
This adds support to make it possible to set the begin frame source in Scheduler back to null before setting it to something else again. This is primarily to support the use case of losing an output surface (which will provide the begin frame source) before asynchronously later initializing another output surface (with potentially another source). In this case, there will be some period of time where there is no valid begin frame source. The scheduler owner could provide a fake one, but I think that's more confusing than helpful. Depends on https://codereview.chromium.org/1774323003 CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel Review URL: https://codereview.chromium.org/1781663004 Cr-Commit-Position: refs/heads/master@{#382016}
Diffstat (limited to 'cc/test')
-rw-r--r--cc/test/scheduler_test_common.h4
1 files changed, 3 insertions, 1 deletions
diff --git a/cc/test/scheduler_test_common.h b/cc/test/scheduler_test_common.h
index 414f31f..eac4983 100644
--- a/cc/test/scheduler_test_common.h
+++ b/cc/test/scheduler_test_common.h
@@ -238,7 +238,9 @@ class TestScheduler : public Scheduler {
return state_machine_.main_thread_missed_last_deadline();
}
- bool begin_frames_expected() const { return observing_begin_frame_source_; }
+ bool begin_frames_expected() const {
+ return begin_frame_source_ && observing_begin_frame_source_;
+ }
~TestScheduler() override;