weex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cxf...@apache.org
Subject [09/25] incubator-weex git commit: * [ios] when viewport is device-width, the width to be adapted should not multiply by scale
Date Thu, 02 Mar 2017 03:28:43 GMT
* [ios] when viewport is device-width,  the width to be adapted  should not multiply by scale


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

Branch: refs/heads/0.11-dev-recycler
Commit: 027757128684d15b6742284dbe42f8bae200a237
Parents: 1c96da7
Author: 隐风 <cxfeng1@gmail.com>
Authored: Thu Feb 23 16:24:23 2017 +0800
Committer: 隐风 <cxfeng1@gmail.com>
Committed: Thu Feb 23 16:24:23 2017 +0800

----------------------------------------------------------------------
 ios/sdk/WeexSDK/Sources/Module/WXMetaModule.m | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/02775712/ios/sdk/WeexSDK/Sources/Module/WXMetaModule.m
----------------------------------------------------------------------
diff --git a/ios/sdk/WeexSDK/Sources/Module/WXMetaModule.m b/ios/sdk/WeexSDK/Sources/Module/WXMetaModule.m
index 3fa4f66..af8c2d0 100644
--- a/ios/sdk/WeexSDK/Sources/Module/WXMetaModule.m
+++ b/ios/sdk/WeexSDK/Sources/Module/WXMetaModule.m
@@ -22,9 +22,9 @@ WX_EXPORT_METHOD(@selector(setViewport:))
     id viewportWidth = viewportArguments[@"width"];
     if ([viewportWidth isKindOfClass:[NSString class]]) {
         if ([viewportWidth isEqualToString:@"device-width"]) {
-            viewportWidthFloat = [WXUtility portraitScreenSize].width * WXScreenScale();
+            viewportWidthFloat = [WXUtility portraitScreenSize].width;
         } else if ([viewportWidth isEqualToString:@"device-height"]) {
-            viewportWidthFloat = [WXUtility portraitScreenSize].height * WXScreenScale();
+            viewportWidthFloat = [WXUtility portraitScreenSize].height;
         } else {
             viewportWidthFloat = [WXConvert CGFloat:viewportWidth];
         }


Mime
View raw message