Move image fetching form #initialize to #fetchImageResources
authorStefan Vogel <sv@exept.de>
Fri, 19 Sep 1997 18:15:52 +0200
changeset 321 9b6c937e218d
parent 320 5915a3370a59
child 322 15310b9a9b27
Move image fetching form #initialize to #fetchImageResources (on request of ca).
UIPainter.st
--- a/UIPainter.st	Fri Sep 19 11:09:43 1997 +0200
+++ b/UIPainter.st	Fri Sep 19 18:15:52 1997 +0200
@@ -3026,19 +3026,42 @@
 
 !UIPainter::TreeView methodsFor:'initialization'!
 
+fetchImageResources
+    "get special images for UIPainter,
+     returns the maximum extent of all images"
+
+    |extent|
+
+    extent := super fetchImageResources.
+
+    imageMasterChild := self class imageMasterChild. 
+    imageMasterChild notNil ifTrue:[
+        imageMasterChild := imageMasterChild onDevice:device.
+        extent := extent max:(imageMasterChild extent).
+    ].
+    imageMasterParent := self class imageMasterParent. 
+    imageMasterParent notNil ifTrue:[
+        imageMasterParent := imageMasterParent onDevice:device.
+        extent := extent max:(imageMasterParent extent).
+    ].
+    imageEmptyParent := self class imageEmptyParent.  
+    imageEmptyParent notNil ifTrue:[
+        imageEmptyParent := imageEmptyParent onDevice:device.
+        extent := extent max:(imageEmptyParent extent).
+    ].
+
+    ^ extent.
+
+    "Modified: 19.9.1997 / 17:18:46 / stefan"
+!
+
 initialize
     "initialization; set multiple select and model
     "
     super initialize.
     self multipleSelectOk:true.
 
-    cvsEventsDisabled := false.
-    imageMasterChild  := self class imageMasterChild. 
-    imageMasterChild notNil ifTrue:[imageMasterChild := imageMasterChild onDevice:device].
-    imageMasterParent := self class imageMasterParent. 
-    imageMasterParent notNil ifTrue:[imageMasterParent := imageMasterParent onDevice:device].
-    imageEmptyParent  := self class imageEmptyParent.  
-    imageEmptyParent notNil ifTrue:[imageEmptyParent := imageEmptyParent onDevice:device].
+    "Modified: 19.9.1997 / 16:57:12 / stefan"
 ! !
 
 !UIPainter::TreeView methodsFor:'private'!