Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3419)

Unified Diff: cc/test/fake_recording_source.cc

Issue 2141233002: cc: Clean up RecordingSource API (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove recoding_source_ from PictureLayer, and move all its internal state to PictureLayer Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: cc/test/fake_recording_source.cc
diff --git a/cc/test/fake_recording_source.cc b/cc/test/fake_recording_source.cc
index 01e4fd01bb37dc1acc595503a1154d522efd1bfd..b816246896fc062a7a7b84b8df6f0712310e3f88 100644
--- a/cc/test/fake_recording_source.cc
+++ b/cc/test/fake_recording_source.cc
@@ -28,24 +28,27 @@ scoped_refptr<RasterSource> FakeRecordingSource::CreateRasterSource(
bool FakeRecordingSource::EqualsTo(const FakeRecordingSource& other) {
// The DisplayItemLists are equal if they are both null or they are both not
// null and render to the same thing.
- bool display_lists_equal = !display_list_ && !other.display_list_;
- if (display_list_ && other.display_list_) {
+ bool display_lists_equal =
+ !clc_data_.display_list && !other.clc_data_.display_list;
+ if (clc_data_.display_list && other.clc_data_.display_list) {
Menglin 2016/07/19 22:56:37 Oh I think you don't have to look into the change
display_lists_equal = AreDisplayListDrawingResultsSame(
- recorded_viewport_, display_list_.get(), other.display_list_.get());
+ clc_data_.recorded_viewport, clc_data_.display_list.get(),
+ other.clc_data_.display_list.get());
}
- return recorded_viewport_ == other.recorded_viewport_ &&
- size_ == other.size_ &&
- slow_down_raster_scale_factor_for_debug_ ==
- other.slow_down_raster_scale_factor_for_debug_ &&
- generate_discardable_images_metadata_ ==
- other.generate_discardable_images_metadata_ &&
- requires_clear_ == other.requires_clear_ &&
- is_solid_color_ == other.is_solid_color_ &&
- clear_canvas_with_debug_color_ ==
- other.clear_canvas_with_debug_color_ &&
- solid_color_ == other.solid_color_ &&
- background_color_ == other.background_color_ && display_lists_equal;
+ return clc_data_.recorded_viewport == other.clc_data_.recorded_viewport &&
+ pl_data_.size == other.pl_data_.size &&
+ pl_data_.slow_down_raster_scale_factor_for_debug ==
+ other.pl_data_.slow_down_raster_scale_factor_for_debug &&
+ pl_data_.generate_discardable_images_metadata ==
+ other.pl_data_.generate_discardable_images_metadata &&
+ pl_data_.requires_clear == other.pl_data_.requires_clear &&
+ pl_data_.is_solid_color == other.pl_data_.is_solid_color &&
+ pl_data_.clear_canvas_with_debug_color ==
+ other.pl_data_.clear_canvas_with_debug_color &&
+ pl_data_.solid_color == other.pl_data_.solid_color &&
+ pl_data_.background_color == other.pl_data_.background_color &&
+ display_lists_equal;
}
} // namespace cc

Powered by Google App Engine
This is Rietveld 408576698