You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by so...@apache.org on 2017/02/28 02:30:14 UTC

[34/50] incubator-weex git commit: + [ios] when update , if originalBoxShadow is nil , get it from view

+ [ios] when update ,if originalBoxShadow is nil ,get it from view


Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/eae99cb7
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/eae99cb7
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/eae99cb7

Branch: refs/heads/0.11-dev
Commit: eae99cb7a84e327c54720ac425ddcb66863d041b
Parents: a23659b
Author: \u9f50\u5c71 <su...@163.com>
Authored: Thu Feb 23 22:12:08 2017 +0800
Committer: \u9f50\u5c71 <su...@163.com>
Committed: Thu Feb 23 22:12:08 2017 +0800

----------------------------------------------------------------------
 ios/sdk/WeexSDK/Sources/Layout/WXComponent+Layout.m | 3 +++
 1 file changed, 3 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/eae99cb7/ios/sdk/WeexSDK/Sources/Layout/WXComponent+Layout.m
----------------------------------------------------------------------
diff --git a/ios/sdk/WeexSDK/Sources/Layout/WXComponent+Layout.m b/ios/sdk/WeexSDK/Sources/Layout/WXComponent+Layout.m
index d457733..ad5b338 100644
--- a/ios/sdk/WeexSDK/Sources/Layout/WXComponent+Layout.m
+++ b/ios/sdk/WeexSDK/Sources/Layout/WXComponent+Layout.m
@@ -118,6 +118,9 @@
             
             strongSelf.view.frame = strongSelf.calculatedFrame;
             if (![WXBoxShadow EqualBoxShadow:_boxShadow withBoxShadow:_lastBoxShadow]) {
+                if (!_originalBoxShadow) {
+                    _originalBoxShadow = [WXBoxShadow getViewBoxShadow:strongSelf.view];
+                }
                 [WXBoxShadow configViewLayer:strongSelf.view boxShadow:_boxShadow lastBoxShadow:_lastBoxShadow originalBoxShadow:_originalBoxShadow];
             }