flex-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ha...@apache.org
Subject git commit: [flex-asjs] [refs/heads/tlf] - Added floor to binary search
Date Sun, 11 Jun 2017 09:39:24 GMT
Repository: flex-asjs
Updated Branches:
  refs/heads/tlf a31c2b710 -> 9af3c0d83


Added floor to binary search


Project: http://git-wip-us.apache.org/repos/asf/flex-asjs/repo
Commit: http://git-wip-us.apache.org/repos/asf/flex-asjs/commit/9af3c0d8
Tree: http://git-wip-us.apache.org/repos/asf/flex-asjs/tree/9af3c0d8
Diff: http://git-wip-us.apache.org/repos/asf/flex-asjs/diff/9af3c0d8

Branch: refs/heads/tlf
Commit: 9af3c0d83fdcb72a0a2cac7165538e9b9709826b
Parents: a31c2b7
Author: Added floor to binary search <harbs@harbss-mbp-2.mynet>
Authored: Sun Jun 11 12:39:20 2017 +0300
Committer: Added floor to binary search <harbs@harbss-mbp-2.mynet>
Committed: Sun Jun 11 12:39:20 2017 +0300

----------------------------------------------------------------------
 .../org/apache/flex/textLayout/compose/StandardFlowComposer.as     | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/9af3c0d8/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/compose/StandardFlowComposer.as
----------------------------------------------------------------------
diff --git a/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/compose/StandardFlowComposer.as
b/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/compose/StandardFlowComposer.as
index bf7d081..f096bb1 100644
--- a/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/compose/StandardFlowComposer.as
+++ b/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/compose/StandardFlowComposer.as
@@ -442,7 +442,7 @@ package org.apache.flex.textLayout.compose
 			var hi:int = _controllerList.length-1;
 			while (lo <= hi)
 			{
-				var mid:int = (lo+hi)/2;
+				var mid:int = Math.floor((lo+hi)/2);
 				var cont:IContainerController = _controllerList[mid];
 				if (cont.absoluteStart <= absolutePosition)
 				{


Mime
View raw message