checkin from browser
authorClaus Gittinger <cg@exept.de>
Tue, 22 Oct 1996 22:27:53 +0200
changeset 1805 5d0aa9e488c5
parent 1804 6bfcf20ed1da
child 1806 071c1c9e6bbb
checkin from browser
Method.st
--- a/Method.st	Tue Oct 22 22:19:05 1996 +0200
+++ b/Method.st	Tue Oct 22 22:27:53 1996 +0200
@@ -1544,30 +1544,26 @@
     "return a printString to represent myself to the user in a browser.
      Defined here to allow for browsers to deal with nonStandard pseudoMethods"
 
-    |s privInfo moreInfo p em i|
+    |s privInfo moreInfo p i|
 
     moreInfo := ''.
     privInfo := ''.
 
-    (p := self privacy) ~~ #public ifTrue:[
-        privInfo := Text string:'    (* ' , p , ' *)' emphasis:#italic.
-    ].
-
     self isWrapped ifTrue:[
         (MessageTracer isCounting:self) ifTrue:[
             (MessageTracer isCountingMemoryUsage:self) ifTrue:[
                 moreInfo := moreInfo , 
-                     '    (mem usage ' , (MessageTracer memoryUsageOfMethod:self) printString , ' Bytes)'.
+                     ' (mem usage ' , (MessageTracer memoryUsageOfMethod:self) printString , ' Bytes)'.
             ] ifFalse:[
                 moreInfo := moreInfo , 
-                     '    (called ' , (MessageTracer executionCountOfMethod:self) printString , ' times)'.
+                     ' (called ' , (MessageTracer executionCountOfMethod:self) printString , ' times)'.
             ]
         ] ifFalse:[
             (MessageTracer isTiming:self) ifTrue:[
                 i := MessageTracer executionTimesOfMethod:self.
                 i notNil ifTrue:[
                     moreInfo := moreInfo , 
-                                '    (avg: ' , (i at:#avgTime) printString,
+                                ' (avg: ' , (i at:#avgTime) printString,
                                 ' min: ' , (i at:#minTime) printString , 
                                 ' max: ' , (i at:#maxTime) printString ,
                                 ' cnt: ' , (i at:#count) printString , ')'
@@ -1575,20 +1571,22 @@
             ] ifFalse:[
                 moreInfo := ' !!'
             ]
-        ]
+        ].
+        p := self originalMethod privacy
+    ] ifFalse:[
+        p := self privacy
+    ].
+
+    p ~~ #public ifTrue:[
+        privInfo := (' (* ' , p , ' *)') asText emphasizeAllWith:#italic.
     ].
 
     self isInvalid ifTrue:[
-        moreInfo := '    (** not executable **)'.
-        em := #color->Color red.
+        moreInfo := ' (** not executable **)' asText emphasizeAllWith:#color->Color red.
     ].
 
-    self isLazyMethod ifTrue:[
-"/                moreInfo := '    (lazy)'
-    ] ifFalse:[
-        self isUnloaded ifTrue:[
-            moreInfo := '    (** unloaded **)'
-        ]
+    self isUnloaded ifTrue:[
+        moreInfo := ' (** unloaded **)'
     ].
 
     privInfo size ~~ 0 ifTrue:[
@@ -1596,14 +1594,13 @@
     ].
 
     moreInfo size == 0 ifTrue:[^ selector].
+
     s := selector , moreInfo.
-    em notNil ifTrue:[
-        ^ Text string:s emphasis:em
-    ].
+Transcript showCR:s.
     ^ s
 
     "Created: 16.4.1996 / 20:11:12 / cg"
-    "Modified: 22.10.1996 / 19:48:07 / cg"
+    "Modified: 22.10.1996 / 21:20:48 / cg"
 !
 
 whoString
@@ -2121,6 +2118,6 @@
 !Method class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/Method.st,v 1.101 1996-10-22 19:25:28 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Method.st,v 1.102 1996-10-22 20:27:53 cg Exp $'
 ! !
 Method initialize!