Index: cc/blink/web_content_layer_impl.cc |
diff --git a/cc/blink/web_content_layer_impl.cc b/cc/blink/web_content_layer_impl.cc |
index 6dfdad9c160fc56d7d7ef7e88863aebc33617c20..061cc2797ba6cca1a03728c5cfb95dbeb2fffe7f 100644 |
--- a/cc/blink/web_content_layer_impl.cc |
+++ b/cc/blink/web_content_layer_impl.cc |
@@ -19,13 +19,12 @@ using cc::PictureLayer; |
namespace cc_blink { |
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() { |
@@ -50,6 +49,8 @@ void WebContentLayerImpl::setDrawCheckerboardForMissingTiles(bool enable) { |
void WebContentLayerImpl::PaintContents( |
SkCanvas* canvas, |
const gfx::Rect& clip, |
+ bool can_use_lcd_text, |
+ bool contents_opaque, |
ContentLayerClient::GraphicsContextStatus graphics_context_status) { |
if (!client_) |
return; |
@@ -57,27 +58,13 @@ void WebContentLayerImpl::PaintContents( |
client_->paintContents( |
canvas, |
clip, |
- can_use_lcd_text_, |
+ can_use_lcd_text, |
+ contents_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; |
} |