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

Unified Diff: cc/LayerChromium.cpp

Issue 11027045: Mark layers whether they can use LCD text depending on content-opacity, draw-opacity, and draw-tran… (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Renamed useLCDText to canUseLCDText Created 8 years, 2 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/LayerChromium.h ('k') | cc/LayerChromiumTest.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/LayerChromium.cpp
diff --git a/cc/LayerChromium.cpp b/cc/LayerChromium.cpp
index d271eb47e12de5470eba0e9a4957052450bee326..c3d399f2365ea47b4a024c2019ba6dd512da9b33 100644
--- a/cc/LayerChromium.cpp
+++ b/cc/LayerChromium.cpp
@@ -52,7 +52,7 @@ LayerChromium::LayerChromium()
, m_masksToBounds(false)
, m_contentsOpaque(false)
, m_doubleSided(true)
- , m_useLCDText(false)
+ , m_canUseLCDText(false)
, m_preserves3D(false)
, m_useParentBackfaceVisibility(false)
, m_drawCheckerboardForMissingTiles(false)
@@ -84,9 +84,13 @@ LayerChromium::~LayerChromium()
removeAllChildren();
}
-void LayerChromium::setUseLCDText(bool useLCDText)
+void LayerChromium::setCanUseLCDText(bool canUseLCDText)
{
- m_useLCDText = useLCDText;
+ if (m_canUseLCDText == canUseLCDText)
+ return;
+
+ m_canUseLCDText = canUseLCDText;
+ setNeedsDisplay();
}
void LayerChromium::setLayerTreeHost(CCLayerTreeHost* host)
@@ -546,7 +550,7 @@ void LayerChromium::pushPropertiesTo(CCLayerImpl* layer)
layer->setDrawsContent(drawsContent());
layer->setFilters(filters());
layer->setBackgroundFilters(backgroundFilters());
- layer->setUseLCDText(m_useLCDText);
+ layer->setCanUseLCDText(m_canUseLCDText);
layer->setMasksToBounds(m_masksToBounds);
layer->setScrollable(m_scrollable);
layer->setShouldScrollOnMainThread(m_shouldScrollOnMainThread);
« no previous file with comments | « cc/LayerChromium.h ('k') | cc/LayerChromiumTest.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698