You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by ac...@apache.org on 2017/08/03 09:51:21 UTC
[3/6] incubator-weex git commit: * [ios] comment about none value
@nodanger
* [ios] comment about none value @nodanger
Project: http://git-wip-us.apache.org/repos/asf/incubator-weex/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-weex/commit/53e96f54
Tree: http://git-wip-us.apache.org/repos/asf/incubator-weex/tree/53e96f54
Diff: http://git-wip-us.apache.org/repos/asf/incubator-weex/diff/53e96f54
Branch: refs/heads/0.16-dev
Commit: 53e96f54f657bd16c3d532ac558013e459a01fb6
Parents: 2ad05e5
Author: acton393 <zh...@gmail.com>
Authored: Wed Jul 26 16:33:55 2017 +0800
Committer: acton393 <zh...@gmail.com>
Committed: Wed Jul 26 16:33:55 2017 +0800
----------------------------------------------------------------------
ios/sdk/WeexSDK/Sources/View/WXComponent+ViewManagement.m | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/53e96f54/ios/sdk/WeexSDK/Sources/View/WXComponent+ViewManagement.m
----------------------------------------------------------------------
diff --git a/ios/sdk/WeexSDK/Sources/View/WXComponent+ViewManagement.m b/ios/sdk/WeexSDK/Sources/View/WXComponent+ViewManagement.m
index 31385de..8f086d4 100644
--- a/ios/sdk/WeexSDK/Sources/View/WXComponent+ViewManagement.m
+++ b/ios/sdk/WeexSDK/Sources/View/WXComponent+ViewManagement.m
@@ -170,6 +170,7 @@ do {\
_lastBoxShadow = _boxShadow;
}
if (styles[@"perspective"]) {
+ // if the perspective is none, treated as 0
_perspective = [WXConvert WXPixelType:styles[@"perspective"] scaleFactor:self.weexInstance.pixelScaleFactor];
if (_perspective <= 0) {
_perspective = CGFLOAT_MAX;
@@ -236,11 +237,12 @@ do {\
}
if (styles[@"perspective"]) {
+ // if the perspective is none, treated as 0
_perspective = [WXConvert WXPixelType:styles[@"perspective"] scaleFactor:self.weexInstance.pixelScaleFactor];
if (_perspective <= 0) {
_perspective = CGFLOAT_MAX;
}
- _transform.perspective = _perspective;
+ _transform.perspective = _perspective;
}
if (styles[@"visibility"]) {