UIPainter.st
changeset 1180 97444c115c14
parent 1177 57a2a0edeb79
child 1185 6c14008722e9
--- a/UIPainter.st	Thu Jul 08 22:17:11 1999 +0200
+++ b/UIPainter.st	Thu Jul 08 22:17:30 1999 +0200
@@ -3341,31 +3341,36 @@
         self doDefineClassAndSelector isNil ifTrue: [^nil]
     ].
 
-    specClass notNil ifTrue:[
-        (specClass includes:$:) ifFalse:[
-            (ns := Smalltalk defaultNameSpace) notNil ifTrue:[
-                cls := ns at:specClass asSymbol
-            ].
-        ].
-        cls isNil ifTrue:[
-            (specClass startsWith:'Smalltalk::') ifTrue:[
-                cls := Smalltalk at: (specClass copyFrom:12) asSymbol.
-            ] ifFalse:[
-                cls := Smalltalk at: specClass asSymbol.
-            ]
-        ].
-        ns := cls nameSpace.
-    ].
-    cls isClass ifFalse:[   
+    (specClass notNil and: [(cls := Smalltalk at: specClass asSymbol) isClass]) ifFalse:[   
         self warn:('Oops - cannot save - class not found: ' , specClass).
         ^nil
     ].
 
-    ns ~~ Smalltalk defaultNameSpace ifTrue:[
-        specClass := ns name , '::' , cls nameWithoutNameSpacePrefix.
-    ] ifFalse:[
-        specClass := cls name.
-    ].
+"/    specClass notNil ifTrue:[
+"/        (specClass includes:$:) ifFalse:[
+"/            (ns := Smalltalk defaultNameSpace) notNil ifTrue:[
+"/                cls := ns at:specClass asSymbol
+"/            ].
+"/        ].
+"/        cls isNil ifTrue:[
+"/            (specClass startsWith:'Smalltalk::') ifTrue:[
+"/                cls := Smalltalk at: (specClass copyFrom:12) asSymbol.
+"/            ] ifFalse:[
+"/                cls := Smalltalk at: specClass asSymbol.
+"/            ]
+"/        ].
+"/        ns := cls nameSpace.
+"/    ].
+"/    cls isClass ifFalse:[   
+"/        self warn:('Oops - cannot save - class not found: ' , specClass).
+"/        ^nil
+"/    ].
+"/
+"/    ns ~~ Smalltalk defaultNameSpace ifTrue:[
+"/        specClass := ns name , '::' , cls nameWithoutNameSpacePrefix.
+"/    ] ifFalse:[
+"/        specClass := cls name.
+"/    ].
 
     painter := self painter.
     painter