SelectionInTreeView.st
changeset 1620 99124a1a1342
parent 1477 b607b899c4df
child 1624 1062c88430f9
--- a/SelectionInTreeView.st	Wed Nov 24 13:12:33 1999 +0100
+++ b/SelectionInTreeView.st	Mon Nov 29 12:38:11 1999 +0100
@@ -787,15 +787,17 @@
     "/ draw directory indicator
 
     img := node isCollapsable ifTrue:[openIndicator] ifFalse:[closeIndicator].
-    ext := img extent // 2.
-    dX  := ext x.
-
-    (x + dX > 0 and:[(x := x - dX) < (width - margin)]) ifTrue:[
-        (self isInSelection:aLineNr) ifTrue:[ self paint:hilightFgColor on:hilightBgColor ]
-                                    ifFalse:[ self paint:fgColor on:bgColor ].
-
-        y := (self yOfVisibleLine:visLn) + (fontHeight // 2) - 1.
-        self displayForm:img x:x y:(y - ext y)
+    img notNil ifTrue:[
+        ext := img extent // 2.
+        dX  := ext x.
+
+        (x + dX > 0 and:[(x := x - dX) < (width - margin)]) ifTrue:[
+            (self isInSelection:aLineNr) ifTrue:[ self paint:hilightFgColor on:hilightBgColor ]
+                                        ifFalse:[ self paint:fgColor on:bgColor ].
+
+            y := (self yOfVisibleLine:visLn) + (fontHeight // 2) - 1.
+            self displayForm:img x:x y:(y - ext y)
+        ].
     ].
 
 
@@ -2370,5 +2372,5 @@
 !SelectionInTreeView class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg2/SelectionInTreeView.st,v 1.86 1999-08-18 14:35:51 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg2/SelectionInTreeView.st,v 1.87 1999-11-29 11:38:11 cg Exp $'
 ! !