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

Unified Diff: third_party/WebKit/Source/core/paint/BoxPainter.cpp

Issue 2641173008: [SPv2] Add CSS mask support (Closed)
Patch Set: rebase Created 3 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
Index: third_party/WebKit/Source/core/paint/BoxPainter.cpp
diff --git a/third_party/WebKit/Source/core/paint/BoxPainter.cpp b/third_party/WebKit/Source/core/paint/BoxPainter.cpp
index a4ca99e2cc0665f07b38d81b235a74afa2ef81f8..bb81359501802a34989f70d11dbc354555e94a4c 100644
--- a/third_party/WebKit/Source/core/paint/BoxPainter.cpp
+++ b/third_party/WebKit/Source/core/paint/BoxPainter.cpp
@@ -816,14 +816,15 @@ void BoxPainter::paintMaskImages(const PaintInfo& paintInfo,
const LayoutRect& paintRect) {
// Figure out if we need to push a transparency layer to render our mask.
bool pushTransparencyLayer = false;
- bool compositedMask =
- m_layoutBox.hasLayer() && m_layoutBox.layer()->hasCompositedMask();
bool flattenCompositingLayers =
paintInfo.getGlobalPaintFlags() & GlobalPaintFlattenCompositingLayers;
+ bool maskBlendingAppliedByCompositor =
+ !flattenCompositingLayers && m_layoutBox.hasLayer() &&
+ m_layoutBox.layer()->maskBlendingAppliedByCompositor();
bool allMaskImagesLoaded = true;
- if (!compositedMask || flattenCompositingLayers) {
+ if (!maskBlendingAppliedByCompositor) {
pushTransparencyLayer = true;
StyleImage* maskBoxImage = m_layoutBox.style()->maskBoxImage().image();
const FillLayer& maskLayers = m_layoutBox.style()->maskLayers();

Powered by Google App Engine
This is Rietveld 408576698