| 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 #include "cc/test/fake_display_list_raster_source.h" | 5 #include "cc/test/fake_display_list_raster_source.h" |
| 6 | 6 |
| 7 #include <limits> | 7 #include <limits> |
| 8 | 8 |
| 9 #include "base/synchronization/waitable_event.h" | 9 #include "base/synchronization/waitable_event.h" |
| 10 #include "cc/test/fake_display_list_recording_source.h" | 10 #include "cc/test/fake_display_list_recording_source.h" |
| (...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 141 base::WaitableEvent* playback_allowed_event) | 141 base::WaitableEvent* playback_allowed_event) |
| 142 : DisplayListRasterSource(recording_source, can_use_lcd), | 142 : DisplayListRasterSource(recording_source, can_use_lcd), |
| 143 playback_allowed_event_(playback_allowed_event) {} | 143 playback_allowed_event_(playback_allowed_event) {} |
| 144 | 144 |
| 145 FakeDisplayListRasterSource::~FakeDisplayListRasterSource() {} | 145 FakeDisplayListRasterSource::~FakeDisplayListRasterSource() {} |
| 146 | 146 |
| 147 void FakeDisplayListRasterSource::PlaybackToCanvas( | 147 void FakeDisplayListRasterSource::PlaybackToCanvas( |
| 148 SkCanvas* canvas, | 148 SkCanvas* canvas, |
| 149 const gfx::Rect& canvas_bitmap_rect, | 149 const gfx::Rect& canvas_bitmap_rect, |
| 150 const gfx::Rect& canvas_playback_rect, | 150 const gfx::Rect& canvas_playback_rect, |
| 151 float contents_scale) const { | 151 float contents_scale, |
| 152 bool include_images) const { |
| 152 if (playback_allowed_event_) | 153 if (playback_allowed_event_) |
| 153 playback_allowed_event_->Wait(); | 154 playback_allowed_event_->Wait(); |
| 154 DisplayListRasterSource::PlaybackToCanvas( | 155 DisplayListRasterSource::PlaybackToCanvas(canvas, canvas_bitmap_rect, |
| 155 canvas, canvas_bitmap_rect, canvas_playback_rect, contents_scale); | 156 canvas_playback_rect, |
| 157 contents_scale, include_images); |
| 156 } | 158 } |
| 157 | 159 |
| 158 } // namespace cc | 160 } // namespace cc |
| OLD | NEW |