added:
authorClaus Gittinger <cg@exept.de>
Tue, 09 Feb 2010 11:05:06 +0100
changeset 9370 daf95953c10f
parent 9369 848e66d8771c
child 9371 d0828a270e10
added: #pseudoFieldNames #pseudoFieldNamesWithIndexed: changed: #fieldList
InspectorView.st
--- a/InspectorView.st	Mon Feb 08 20:51:09 2010 +0100
+++ b/InspectorView.st	Tue Feb 09 11:05:06 2010 +0100
@@ -1353,25 +1353,7 @@
         self hasSelfEntry ifTrue:[
             self suppressPseudoSlots ifFalse:[
                 derivedFieldList := OrderedCollection new.
-                derivedFieldList add:'-' , 'self' allItalic.
-                derivedFieldList add:'-' , 'local messages' allItalic.
-                "/ derivedFieldList add:'-' , 'inherited messages' allItalic.
-                derivedFieldList add:'-' , 'all messages' allItalic.
-                derivedFieldList add:'-' , 'hash' allItalic.
-                derivedFieldList add:'-' , 'identityHash' allItalic.
-
-                cls hasImmediateInstances ifFalse:[
-                    object dependents notEmptyOrNil ifTrue:[
-                        derivedFieldList add:'-' , 'dependents' allItalic.
-                    ].
-                ].
-                cls instSize > 0 ifTrue:[
-                    derivedFieldList add:'-' , 'all inst vars' allItalic.
-                ].
-                (indexedList notEmptyOrNil and:[self showAllIndexedVarsInFieldList]) ifTrue:[
-                    derivedFieldList add:'-' , 'all indexed vars' allItalic.
-                ].
-
+                derivedFieldList addAll:(self pseudoFieldNamesWithIndexed:(indexedList notEmptyOrNil)).
                 derivedFieldList addAll:(self derivedFieldNames).
                 extraNamedFieldList addAll:(self extraNamedFieldNames).
             ].
@@ -1579,6 +1561,66 @@
     "Modified: / 18-09-2006 / 21:35:30 / cg"
 !
 
+pseudoFieldNames
+    "return a list of names to show in the selectionList.
+     Leave hasMore as true, if a '...' entry should be added."
+
+    |list cls|
+
+    cls := object class.
+
+    list := OrderedCollection new.
+    list add:'-' , 'self' allItalic.
+    list add:'-' , 'local messages' allItalic.
+    "/ list add:'-' , 'inherited messages' allItalic.
+    list add:'-' , 'all messages' allItalic.
+    list add:'-' , 'hash' allItalic.
+    list add:'-' , 'identityHash' allItalic.
+
+    cls hasImmediateInstances ifFalse:[
+        object dependents notEmptyOrNil ifTrue:[
+            list add:'-' , 'dependents' allItalic.
+        ].
+    ].
+    cls instSize > 0 ifTrue:[
+        list add:'-' , 'all inst vars' allItalic.
+    ].
+    ((cls isVariable) and:[self showAllIndexedVarsInFieldList]) ifTrue:[
+        list add:'-' , 'all indexed vars' allItalic.
+    ].
+    ^ list
+!
+
+pseudoFieldNamesWithIndexed:withIndexed
+    "return a list of names to show in the selectionList.
+     Leave hasMore as true, if a '...' entry should be added."
+
+    |list cls|
+
+    cls := object class.
+
+    list := OrderedCollection new.
+    list add:'-' , 'self' allItalic.
+    list add:'-' , 'local messages' allItalic.
+    "/ list add:'-' , 'inherited messages' allItalic.
+    list add:'-' , 'all messages' allItalic.
+    list add:'-' , 'hash' allItalic.
+    list add:'-' , 'identityHash' allItalic.
+
+    cls hasImmediateInstances ifFalse:[
+        object dependents notEmptyOrNil ifTrue:[
+            list add:'-' , 'dependents' allItalic.
+        ].
+    ].
+    cls instSize > 0 ifTrue:[
+        list add:'-' , 'all inst vars' allItalic.
+    ].
+    (withIndexed and:[self showAllIndexedVarsInFieldList]) ifTrue:[
+        list add:'-' , 'all indexed vars' allItalic.
+    ].
+    ^ list
+!
+
 setAcceptAction
     "set the codeViews accept action"
 
@@ -2249,9 +2291,9 @@
 !InspectorView class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libtool/InspectorView.st,v 1.206 2010-02-06 17:57:29 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libtool/InspectorView.st,v 1.207 2010-02-09 10:05:06 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libtool/InspectorView.st,v 1.206 2010-02-06 17:57:29 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libtool/InspectorView.st,v 1.207 2010-02-09 10:05:06 cg Exp $'
 ! !