diff --git a/components/Shapes/src/MDCShapedShadowLayer.m b/components/Shapes/src/MDCShapedShadowLayer.m index 9d1e4ee0ddb..fba26580adc 100644 --- a/components/Shapes/src/MDCShapedShadowLayer.m +++ b/components/Shapes/src/MDCShapedShadowLayer.m @@ -113,6 +113,7 @@ - (void)setPath:(CGPathRef)path { - (void)generateColorPathGivenLineWidth { if (CGPathIsEmpty(self.path) || _colorLayer.lineWidth <= 0) { + _colorLayer.path = _shapeLayer.path; return; } CGFloat halfOfBorderWidth = self.shapedBorderWidth / 2.f; @@ -126,7 +127,7 @@ - (void)generateColorPathGivenLineWidth { transform = CGAffineTransformScale(transform, CGRectGetWidth(insetBounds) / width, CGRectGetHeight(insetBounds) / height); } - _colorLayer.path = CGPathCreateCopyByTransformingPath(_colorLayer.path, &transform); + _colorLayer.path = CGPathCreateCopyByTransformingPath(_shapeLayer.path, &transform); } - (CGPathRef)path {