class: VersionDiffBrowser
authorClaus Gittinger <cg@exept.de>
Sat, 23 Mar 2013 12:37:08 +0100
changeset 12512 072f76033d49
parent 12511 2edbe2a9d758
child 12513 b1aca0771123
class: VersionDiffBrowser changed: #methodsChangedSelectionChanged category of: #methodsChangedSelectionChanged #methodsOnlyInASelectionChanged #methodsOnlyInBSelectionChanged
VersionDiffBrowser.st
--- a/VersionDiffBrowser.st	Fri Mar 22 14:49:46 2013 +0100
+++ b/VersionDiffBrowser.st	Sat Mar 23 12:37:08 2013 +0100
@@ -1007,98 +1007,6 @@
     self browseClassInM.
 !
 
-methodsChangedSelectionChanged
-    "
-    the selection in the list of the 'changed methods' changed.
-    Reset the selection of the two other lists and calc the method change.
-
-    <return: self>
-    "
-    |sel changeA changeB methodsChanged parseError treeA treeB|
-
-    self infoHolder value:''.
-
-    sel := self methodsChangedSelection value.
-    sel notNil ifTrue:[
-        self methodsOnlyInASelection value:nil.
-        self methodsOnlyInBSelection value:nil.
-        methodsChanged := self classChangeSet methodsChanged.
-        changeA := (methodsChangedFiltered at:sel) first.
-        changeB := (methodsChangedFiltered at:sel) second.
-        self withReadCursorDo:[
-            "/ see if the semantics have changed (or only prettyPrinted)
-            RBParser notNil ifTrue:[
-                (classChangeSet notNil
-                and:[ classChangeSet classBeingCompared notNil ]) ifTrue:[
-                    parseError := false.
-                    treeA := RBParser parseMethod:changeA source onError: [:str :pos | parseError := true].
-                    treeB := RBParser parseMethod:changeB source onError: [:str :pos | parseError := true].
-                    parseError ifFalse:[
-                        (treeA equalTo:treeB withMapping:(Dictionary  new)) ifTrue:[
-                            self infoHolder value:'Methods only differ in formatting / comments.'.
-                        ]
-                    ]
-                ].
-            ].
-            self diffTextView
-                text1:(changeA prettyPrintedSource) text2:(changeB prettyPrintedSource);
-                moveToNextChanged
-        ].
-        self showDiffTextView.
-    ]
-
-    "Modified: / 03-09-1999 / 15:01:30 / ps"
-    "Modified: / 17-07-2012 / 18:27:06 / cg"
-!
-
-methodsOnlyInASelectionChanged
-    "
-    the selection in the list of the 'method only in version A' changed.
-    Reset the selection of the two other lists and show the method in
-    the text view.
-
-    <return: self>
-    "
-    |change sel|
-
-    self infoHolder value:''.
-
-    sel := self methodsOnlyInASelection value.
-    sel notNil ifTrue:[
-        self methodsOnlyInBSelection value:nil.
-        self methodsChangedSelection value:nil.
-        change := methodsOnlyInAFiltered "self changeSetA" at:sel.
-        self methodText value:(change prettyPrintedSource).
-        self showSingleTextView.
-    ]
-
-    "Modified: / 17-07-2012 / 18:31:22 / cg"
-!
-
-methodsOnlyInBSelectionChanged
-    "
-    the selection in the list of the 'method only in version B' changed.
-    Reset the selection of the two other lists and show the method in
-    the text view.
-
-    <return: self>
-    "
-    |change sel|
-
-    self infoHolder value:''.
-
-    sel := self methodsOnlyInBSelection value.
-    sel notNil ifTrue:[
-        self methodsOnlyInASelection value:nil.
-        self methodsChangedSelection value:nil.
-        change := methodsOnlyInBFiltered "self changeSetB" at:sel.
-        self methodText value:(change prettyPrintedSource).
-        self showSingleTextView.
-    ]
-
-    "Modified: / 17-07-2012 / 18:31:32 / cg"
-!
-
 removeSelectedChangeInBFromImage
     |change cls sel op|
 
@@ -1461,6 +1369,99 @@
 
 !VersionDiffBrowser methodsFor:'change & update'!
 
+methodsChangedSelectionChanged
+    "
+    the selection in the list of the 'changed methods' changed.
+    Reset the selection of the two other lists and calc the method change.
+
+    <return: self>
+    "
+    |sel changeA changeB methodsChanged parseError treeA treeB|
+
+    self infoHolder value:''.
+
+    sel := self methodsChangedSelection value.
+    sel notNil ifTrue:[
+        self methodsOnlyInASelection value:nil.
+        self methodsOnlyInBSelection value:nil.
+        methodsChanged := self classChangeSet methodsChanged.
+        changeA := (methodsChangedFiltered at:sel) first.
+        changeB := (methodsChangedFiltered at:sel) second.
+        self withReadCursorDo:[
+            "/ see if the semantics have changed (or only prettyPrinted)
+            RBParser notNil ifTrue:[
+                (classChangeSet notNil
+                and:[ classChangeSet classBeingCompared notNil ]) ifTrue:[
+                    parseError := false.
+                    treeA := RBParser parseMethod:changeA source onError: [:str :pos | parseError := true].
+                    treeB := RBParser parseMethod:changeB source onError: [:str :pos | parseError := true].
+                    parseError ifFalse:[
+                        (treeA equalTo:treeB withMapping:(Dictionary  new)) ifTrue:[
+                            self infoHolder value:'Methods only differ in formatting / comments.'.
+                        ]
+                    ]
+                ].
+            ].
+            self diffTextView
+                text1:(changeA prettyPrintedSource) 
+                text2:(changeB prettyPrintedSource)        
+        ].
+        self showDiffTextView.
+        self diffTextView moveToNextChanged
+    ]
+
+    "Modified: / 03-09-1999 / 15:01:30 / ps"
+    "Modified: / 17-07-2012 / 18:27:06 / cg"
+!
+
+methodsOnlyInASelectionChanged
+    "
+    the selection in the list of the 'method only in version A' changed.
+    Reset the selection of the two other lists and show the method in
+    the text view.
+
+    <return: self>
+    "
+    |change sel|
+
+    self infoHolder value:''.
+
+    sel := self methodsOnlyInASelection value.
+    sel notNil ifTrue:[
+        self methodsOnlyInBSelection value:nil.
+        self methodsChangedSelection value:nil.
+        change := methodsOnlyInAFiltered "self changeSetA" at:sel.
+        self methodText value:(change prettyPrintedSource).
+        self showSingleTextView.
+    ]
+
+    "Modified: / 17-07-2012 / 18:31:22 / cg"
+!
+
+methodsOnlyInBSelectionChanged
+    "
+    the selection in the list of the 'method only in version B' changed.
+    Reset the selection of the two other lists and show the method in
+    the text view.
+
+    <return: self>
+    "
+    |change sel|
+
+    self infoHolder value:''.
+
+    sel := self methodsOnlyInBSelection value.
+    sel notNil ifTrue:[
+        self methodsOnlyInASelection value:nil.
+        self methodsChangedSelection value:nil.
+        change := methodsOnlyInBFiltered "self changeSetB" at:sel.
+        self methodText value:(change prettyPrintedSource).
+        self showSingleTextView.
+    ]
+
+    "Modified: / 17-07-2012 / 18:31:32 / cg"
+!
+
 update:something with:parameter from:changedObject
     ((changedObject == includeExtensionsHolder)
     or:[ changedObject == includeCategoryChangesHolder
@@ -2446,9 +2447,10 @@
 !VersionDiffBrowser class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.111 2012-10-30 16:04:26 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.112 2013-03-23 11:37:08 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.111 2012-10-30 16:04:26 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libtool/VersionDiffBrowser.st,v 1.112 2013-03-23 11:37:08 cg Exp $'
 ! !
+