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

Unified Diff: sky/viewer/cc/web_content_layer_impl.cc

Issue 737943002: Update from https://crrev.com/304715 (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 6 years, 1 month 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 | « sky/viewer/cc/web_content_layer_impl.h ('k') | sky/viewer/cc/web_filter_animation_curve_impl.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/viewer/cc/web_content_layer_impl.cc
diff --git a/sky/viewer/cc/web_content_layer_impl.cc b/sky/viewer/cc/web_content_layer_impl.cc
index 0369b72ea305f38b1842fab97331990154222841..261d3a0be3be4de23cb93ff1955a6bfa1b3926f9 100644
--- a/sky/viewer/cc/web_content_layer_impl.cc
+++ b/sky/viewer/cc/web_content_layer_impl.cc
@@ -19,13 +19,12 @@ using cc::PictureLayer;
namespace sky_viewer_cc {
WebContentLayerImpl::WebContentLayerImpl(blink::WebContentLayerClient* client)
- : client_(client), ignore_lcd_text_change_(false) {
+ : client_(client) {
if (WebLayerImpl::UsingPictureLayer())
layer_ = make_scoped_ptr(new WebLayerImpl(PictureLayer::Create(this)));
else
layer_ = make_scoped_ptr(new WebLayerImpl(ContentLayer::Create(this)));
layer_->layer()->SetIsDrawable(true);
- can_use_lcd_text_ = layer_->layer()->can_use_lcd_text();
}
WebContentLayerImpl::~WebContentLayerImpl() {
@@ -55,31 +54,14 @@ void WebContentLayerImpl::PaintContents(
return;
blink::WebFloatRect web_opaque;
+ bool can_use_lcd_text = false;
client_->paintContents(
- canvas,
- clip,
- can_use_lcd_text_,
- web_opaque,
+ canvas, clip, can_use_lcd_text, web_opaque,
graphics_context_status == ContentLayerClient::GRAPHICS_CONTEXT_ENABLED
? blink::WebContentLayerClient::GraphicsContextEnabled
: blink::WebContentLayerClient::GraphicsContextDisabled);
}
-void WebContentLayerImpl::DidChangeLayerCanUseLCDText() {
- // It is important to make this comparison because the LCD text status
- // here can get out of sync with that in the layer.
- if (can_use_lcd_text_ == layer_->layer()->can_use_lcd_text())
- return;
-
- // LCD text cannot be enabled once disabled.
- if (layer_->layer()->can_use_lcd_text() && ignore_lcd_text_change_)
- return;
-
- can_use_lcd_text_ = layer_->layer()->can_use_lcd_text();
- ignore_lcd_text_change_ = true;
- layer_->invalidate();
-}
-
bool WebContentLayerImpl::FillsBoundsCompletely() const {
return false;
}
« no previous file with comments | « sky/viewer/cc/web_content_layer_impl.h ('k') | sky/viewer/cc/web_filter_animation_curve_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698