Condition not necessary

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

Branch: refs/heads/feature/strand-work
Commit: 8d6d7ca847aa66316050d6b104816ab5382a7288
Parents: bc50901
Author: Harbs <ha...@in-tools.com>
Authored: Mon Aug 7 00:13:33 2017 +0300
Committer: Harbs <ha...@in-tools.com>
Committed: Mon Aug 7 00:13:33 2017 +0300

----------------------------------------------------------------------
 .../flex/textLayout/elements/FlowGroupElement.as      | 14 +-------------
 1 file changed, 1 insertion(+), 13 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/flex-asjs/blob/8d6d7ca8/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/elements/FlowGroupElement.as
----------------------------------------------------------------------
diff --git 
a/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/elements/FlowGroupElement.as
 
b/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/elements/FlowGroupElement.as
index 8664a29..e869c75 100644
--- 
a/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/elements/FlowGroupElement.as
+++ 
b/frameworks/projects/TLF/src/main/flex/org/apache/flex/textLayout/elements/FlowGroupElement.as
@@ -968,19 +968,7 @@ package org.apache.flex.textLayout.elements
 
                                if (curFlowElement.parentRelativeStart != 
relativePosition)
                                {
-                                       if (curFlowElement.className == 
"FlowGroupElement")
-                                       {
-                                               
FlowGroupElement(curFlowElement).splitAtPosition(relativePosition - 
curFlowElement.parentRelativeStart);
-                                       }
-                                       else
-                                       {
-                                               // I would imagine that it has 
to be a span.  That's the only non-FlowGroupElement
-                                               // type that can take up more 
than a textLength of 1.
-                                               CONFIG::debug
-                                               {
-                                                       
assert(curFlowElement.className == "SpanElement", "SpanElements are the only 
leaf elements that can currently have > 1 textLength");    }
-                                               
ISpanElement(curFlowElement).splitAtPosition(relativePosition - 
curFlowElement.parentRelativeStart);
-                                       }
+                                       
curFlowElement.splitAtPosition(relativePosition - 
curFlowElement.parentRelativeStart);
                                        // increase by one. It's the new 
element that we want to move over.
                                        curElementIdx++;
                                }

Reply via email to