Commit 3de2a457 authored by smcgruer's avatar smcgruer Committed by Commit bot

Mark clip paths as a clip-related property

BUG=615870

TEST=Load http://codepen.io/zen-co/pen/jrOxEg and check that the animation is
clipped properly

Review-Url: https://codereview.chromium.org/2558633005
Cr-Commit-Position: refs/heads/master@{#437635}
parent 9b853cfc
<!DOCTYPE html>
<style type="text/css" media="screen">
#parent {
position: absolute;
height: 256px;
width: 256px;
-webkit-clip-path: circle(128px at center);
clip-path: circle(128px at center);
background: #eee;
will-change: transform;
}
#child {
background: #222;
width: 64px;
height: 64px;
will-change: transform;
}
</style>
<div id="parent">
<div id="child"></div>
</div>
<!DOCTYPE html>
<style type="text/css" media="screen">
#parent {
position: absolute;
height: 256px;
width: 256px;
-webkit-clip-path: circle(128px at center);
clip-path: circle(128px at center);
background: #eee;
}
#child {
background: #222;
width: 64px;
height: 64px;
will-change: transform;
}
</style>
<div id="parent">
<div id="child"></div>
</div>
...@@ -805,7 +805,8 @@ class CORE_EXPORT LayoutObject : public ImageResourceObserver, ...@@ -805,7 +805,8 @@ class CORE_EXPORT LayoutObject : public ImageResourceObserver,
} }
bool hasOverflowClip() const { return m_bitfields.hasOverflowClip(); } bool hasOverflowClip() const { return m_bitfields.hasOverflowClip(); }
bool hasClipRelatedProperty() const { bool hasClipRelatedProperty() const {
return hasClip() || hasOverflowClip() || style()->containsPaint(); return hasClip() || hasOverflowClip() || hasClipPath() ||
style()->containsPaint();
} }
bool hasTransformRelatedProperty() const { bool hasTransformRelatedProperty() const {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment