--- a/Tools__Diff2CodeView2.st Thu May 15 19:21:17 2014 +0200
+++ b/Tools__Diff2CodeView2.st Thu May 15 19:21:25 2014 +0200
@@ -86,8 +86,13 @@
computeDiffDataForText1:t1 text2:t2
"created diffText object from two string"
-
- |array1 array2 diff change index1 index2 text1 text2 i data deleted inserted helperText addConstant1 addConstant2 changed helper ins del pom|
+
+ "/ cg: same code as in DiffCodeView2!!!!!!
+ "/ please refactor and make this a utility method on the class side
+
+ |array1 array2 diff change index1 index2 text1 text2 i
+ data deleted inserted helperText addConstant1 addConstant2 changed helper ins del pom
+ array1Size array2Size|
"Convert text into an array of individual lines"
array1 := self createArray:t1.
@@ -183,19 +188,17 @@
change := change nextLink.
].
"kontrola zda nam nechybi posledni znaky"
- (index1 <= (array1 size)) ifTrue:[
- [
- index1 <= (array1 size)
- ] whileTrue:[
+ array1Size := array1 size.
+ (index1 <= array1Size) ifTrue:[
+ [ index1 <= array1Size ] whileTrue:[
helperText := (array1 at:index1) asText.
text1 := text1 , helperText.
index1 := index1 + 1.
].
].
- (index2 <= (array2 size)) ifTrue:[
- [
- index2 <= (array2 size)
- ] whileTrue:[
+ array2Size := array2 size.
+ (index2 <= array2Size) ifTrue:[
+ [ index2 <= (array2 size) ] whileTrue:[
helperText := (array2 at:index2) asText.
text2 := text2 , helperText.
index2 := index2 + 1.
@@ -285,10 +288,10 @@
!Diff2CodeView2 class methodsFor:'documentation'!
version
- ^ '$Header: /cvs/stx/stx/libtool/Tools__Diff2CodeView2.st,v 1.1 2014-02-05 18:58:49 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libtool/Tools__Diff2CodeView2.st,v 1.2 2014-05-15 17:21:25 cg Exp $'
!
version_CVS
- ^ '$Header: /cvs/stx/stx/libtool/Tools__Diff2CodeView2.st,v 1.1 2014-02-05 18:58:49 cg Exp $'
+ ^ '$Header: /cvs/stx/stx/libtool/Tools__Diff2CodeView2.st,v 1.2 2014-05-15 17:21:25 cg Exp $'
! !