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

Unified Diff: cc/resources/display_list_recording_source.cc

Issue 951673002: Revert "Pull chromium at 2c3ffb2355a27c32f45e508ef861416b820c823b" (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: 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_recording_source.h ('k') | cc/resources/drawing_display_item.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/resources/display_list_recording_source.cc
diff --git a/cc/resources/display_list_recording_source.cc b/cc/resources/display_list_recording_source.cc
index 517f49faf0c56f81ff3918fea63f6d988db9b923..01a3bcef9944e2504829e79ad3b40bef46bd5ec7 100644
--- a/cc/resources/display_list_recording_source.cc
+++ b/cc/resources/display_list_recording_source.cc
@@ -28,6 +28,7 @@ namespace cc {
DisplayListRecordingSource::DisplayListRecordingSource()
: slow_down_raster_scale_factor_for_debug_(0),
+ can_use_lcd_text_(true),
requires_clear_(false),
is_solid_color_(false),
solid_color_(SK_ColorTRANSPARENT),
@@ -42,6 +43,7 @@ DisplayListRecordingSource::~DisplayListRecordingSource() {
bool DisplayListRecordingSource::UpdateAndExpandInvalidation(
ContentLayerClient* painter,
Region* invalidation,
+ bool can_use_lcd_text,
const gfx::Size& layer_size,
const gfx::Rect& visible_layer_rect,
int frame_number,
@@ -53,6 +55,12 @@ bool DisplayListRecordingSource::UpdateAndExpandInvalidation(
updated = true;
}
+ if (can_use_lcd_text_ != can_use_lcd_text) {
+ can_use_lcd_text_ = can_use_lcd_text;
+ invalidation->Union(gfx::Rect(GetSize()));
+ updated = true;
+ }
+
gfx::Rect old_recorded_viewport = recorded_viewport_;
recorded_viewport_ = visible_layer_rect;
recorded_viewport_.Inset(-pixel_record_distance_, -pixel_record_distance_);
@@ -144,11 +152,10 @@ bool DisplayListRecordingSource::IsSuitableForGpuRasterization() const {
return is_suitable_for_gpu_rasterization_;
}
-scoped_refptr<RasterSource> DisplayListRecordingSource::CreateRasterSource(
- bool can_use_lcd_text) const {
+scoped_refptr<RasterSource> DisplayListRecordingSource::CreateRasterSource()
+ const {
return scoped_refptr<RasterSource>(
- DisplayListRasterSource::CreateFromDisplayListRecordingSource(
- this, can_use_lcd_text));
+ DisplayListRasterSource::CreateFromDisplayListRecordingSource(this));
}
gfx::Size DisplayListRecordingSource::GetTileGridSizeForTesting() const {
« no previous file with comments | « cc/resources/display_list_recording_source.h ('k') | cc/resources/drawing_display_item.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698