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

Unified Diff: cc/resources/display_list_raster_source.cc

Issue 952893003: Update from https://crrev.com/317530 (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Fix gn for nacl Created 5 years, 10 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
« no previous file with comments | « cc/resources/display_list_raster_source.h ('k') | cc/resources/display_list_recording_source.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/display_list_raster_source.cc
diff --git a/cc/resources/display_list_raster_source.cc b/cc/resources/display_list_raster_source.cc
index 4479a166c3b4942e15f5247b581d01646d5f7bd9..ab0292e8537aabc401e84da6ac8596c686a65a78 100644
--- a/cc/resources/display_list_raster_source.cc
+++ b/cc/resources/display_list_raster_source.cc
@@ -26,14 +26,12 @@ const bool kDefaultClearCanvasSetting = true;
namespace cc {
-scoped_refptr<DisplayListRasterSource> DisplayListRasterSource::Create() {
- return make_scoped_refptr(new DisplayListRasterSource);
-}
-
scoped_refptr<DisplayListRasterSource>
DisplayListRasterSource::CreateFromDisplayListRecordingSource(
- const DisplayListRecordingSource* other) {
- return make_scoped_refptr(new DisplayListRasterSource(other));
+ const DisplayListRecordingSource* other,
+ bool can_use_lcd_text) {
+ return make_scoped_refptr(
+ new DisplayListRasterSource(other, can_use_lcd_text));
}
DisplayListRasterSource::DisplayListRasterSource()
@@ -48,11 +46,12 @@ DisplayListRasterSource::DisplayListRasterSource()
}
DisplayListRasterSource::DisplayListRasterSource(
- const DisplayListRecordingSource* other)
+ const DisplayListRecordingSource* other,
+ bool can_use_lcd_text)
: display_list_(other->display_list_),
background_color_(other->background_color_),
requires_clear_(other->requires_clear_),
- can_use_lcd_text_(other->can_use_lcd_text_),
+ can_use_lcd_text_(can_use_lcd_text),
is_solid_color_(other->is_solid_color_),
solid_color_(other->solid_color_),
recorded_viewport_(other->recorded_viewport_),
@@ -63,6 +62,24 @@ DisplayListRasterSource::DisplayListRasterSource(
should_attempt_to_use_distance_field_text_(false) {
}
+DisplayListRasterSource::DisplayListRasterSource(
+ const DisplayListRasterSource* other,
+ bool can_use_lcd_text)
+ : display_list_(other->display_list_),
+ background_color_(other->background_color_),
+ requires_clear_(other->requires_clear_),
+ can_use_lcd_text_(can_use_lcd_text),
+ is_solid_color_(other->is_solid_color_),
+ solid_color_(other->solid_color_),
+ recorded_viewport_(other->recorded_viewport_),
+ size_(other->size_),
+ clear_canvas_with_debug_color_(kDefaultClearCanvasSetting),
+ slow_down_raster_scale_factor_for_debug_(
+ other->slow_down_raster_scale_factor_for_debug_),
+ should_attempt_to_use_distance_field_text_(
+ other->should_attempt_to_use_distance_field_text_) {
+}
+
DisplayListRasterSource::~DisplayListRasterSource() {
}
@@ -197,4 +214,11 @@ bool DisplayListRasterSource::CanUseLCDText() const {
return can_use_lcd_text_;
}
+scoped_refptr<RasterSource> DisplayListRasterSource::CreateCloneWithoutLCDText()
+ const {
+ bool can_use_lcd_text = false;
+ return scoped_refptr<RasterSource>(
+ new DisplayListRasterSource(this, can_use_lcd_text));
+}
+
} // namespace cc
« no previous file with comments | « cc/resources/display_list_raster_source.h ('k') | cc/resources/display_list_recording_source.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698