You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@weex.apache.org by bo...@apache.org on 2017/04/18 10:50:57 UTC

[5/5] incubator-weex git commit: * [ios] update lineIndex

* [ios] update lineIndex


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

Branch: refs/heads/0.12-dev
Commit: 90c358303096baac16b95b81bdad68c805e8630d
Parents: 1fd7c08
Author: acton393 <zh...@gmail.com>
Authored: Tue Apr 18 18:00:08 2017 +0800
Committer: acton393 <zh...@gmail.com>
Committed: Tue Apr 18 18:00:08 2017 +0800

----------------------------------------------------------------------
 ios/sdk/WeexSDK/Sources/Component/WXTextComponent.m | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-weex/blob/90c35830/ios/sdk/WeexSDK/Sources/Component/WXTextComponent.m
----------------------------------------------------------------------
diff --git a/ios/sdk/WeexSDK/Sources/Component/WXTextComponent.m b/ios/sdk/WeexSDK/Sources/Component/WXTextComponent.m
index fed8dd5..005ca1a 100644
--- a/ios/sdk/WeexSDK/Sources/Component/WXTextComponent.m
+++ b/ios/sdk/WeexSDK/Sources/Component/WXTextComponent.m
@@ -609,7 +609,7 @@ do {\
         BOOL needTruncation = NO;
         CTLineRef ctTruncatedLine = NULL;
         CTFrameGetLineOrigins(_coreTextFrameRef, CFRangeMake(0, 0), lineOrigins);
-        for (CFIndex lineIndex = 0;(!_lines || _lines >= lineIndex) && lineIndex < lineCount; lineIndex ++) {
+        for (CFIndex lineIndex = 0;(!_lines || _lines > lineIndex) && lineIndex < lineCount; lineIndex ++) {
             CTLineRef lineRef = NULL;
             lineRef = CFArrayGetValueAtIndex(ctLines, lineIndex);
             if (!lineRef) {