UIPainter.st
changeset 1194 651885033545
parent 1193 ada18c876301
child 1195 64f3537ca061
--- a/UIPainter.st	Tue Jul 13 21:04:49 1999 +0200
+++ b/UIPainter.st	Tue Jul 13 21:20:48 1999 +0200
@@ -2936,7 +2936,8 @@
 postOpenWith: aBuilder
     "sets the initial selection"
 
-    |myWindow canvasWindow canvasOrg galleryWindow myOrg myCorner|
+    |myWindow canvasWindow canvasOrg galleryWindow 
+     galleryOrg myOrg myCorner|
 
     super postOpenWith: aBuilder.
     treeView selection: #(1).
@@ -2950,23 +2951,19 @@
     myOrg := myWindow origin.
     myCorner := myWindow corner.
 
-    (myCorner x + canvasWindow width + 20) <= device width ifTrue:[
-        canvasOrg := (myCorner x + canvasWindow width) @ (myOrg y).
-    ] ifFalse:[
-        canvasOrg := 0@0.
-        myOrg := (device width - myWindow width - 20) @ 0.
-        myWindow origin:myOrg.
-    ].
+    canvasOrg := 0@0.
+    myOrg := (device width - myWindow width - 20) @ 0.
+    galleryOrg := (device width - galleryWindow width - 20) 
+                  @ 
+                  ((myWindow height + 20) min:(device height - galleryWindow height - 20)).
+    myWindow origin:myOrg.
 
     canvasWindow origin:canvasOrg.
+    galleryWindow origin:galleryOrg.
 
     galleryWindow raise.
     canvasWindow raise.
 
-    galleryWindow 
-        origin:((myOrg corner:myCorner) topCenter x - (galleryWindow width // 2)) rounded
-               @
-               (device height - galleryWindow height - 20).
 
     "Modified: / 22.8.1998 / 17:41:34 / cg"
 ! !