From 4e888775c16bc9fa2b4fff8e2a0b3c3cc045ed79 Mon Sep 17 00:00:00 2001 From: txink <1256065080@qq.com> Date: Wed, 3 Jul 2019 15:57:03 +0800 Subject: [PATCH] fix corner --- ios/sdk/WeexSDK/Sources/Display/WXComponent+Display.m | 1 + ios/sdk/WeexSDK/Sources/Model/WXComponent.mm | 1 + 2 files changed, 2 insertions(+) diff --git a/ios/sdk/WeexSDK/Sources/Display/WXComponent+Display.m b/ios/sdk/WeexSDK/Sources/Display/WXComponent+Display.m index 78ae8c2abe..04e7dda5fa 100644 --- a/ios/sdk/WeexSDK/Sources/Display/WXComponent+Display.m +++ b/ios/sdk/WeexSDK/Sources/Display/WXComponent+Display.m @@ -353,6 +353,7 @@ - (void)_drawBorderWithContext:(CGContextRef)context size:(CGSize)size CGContextSetFillColorWithColor(context, _backgroundColor.CGColor); UIBezierPath *bezierPath = [UIBezierPath wx_bezierPathWithRoundedRect:rect topLeft:topLeft topRight:topRight bottomLeft:bottomLeft bottomRight:bottomRight]; [bezierPath fill]; + _view.backgroundColor = UIColor.clearColor; } // Top if (_borderTopWidth > 0) { diff --git a/ios/sdk/WeexSDK/Sources/Model/WXComponent.mm b/ios/sdk/WeexSDK/Sources/Model/WXComponent.mm index d9c92db930..084d3dc39d 100644 --- a/ios/sdk/WeexSDK/Sources/Model/WXComponent.mm +++ b/ios/sdk/WeexSDK/Sources/Model/WXComponent.mm @@ -850,6 +850,7 @@ - (void)setGradientLayer if (gradientLayer) { _backgroundColor = [UIColor colorWithPatternImage:[strongSelf imageFromLayer:gradientLayer]]; strongSelf.view.backgroundColor = _backgroundColor; + [strongSelf setNeedsDisplay]; } } });