handle redrawing fixed
authorClaus Gittinger <cg@exept.de>
Tue, 07 Jun 2005 17:02:24 +0200
changeset 1911 0538568157f0
parent 1910 4ca9f4b322c9
child 1912 a2f795ace8a9
handle redrawing fixed
UIObjectView.st
--- a/UIObjectView.st	Thu Jun 02 14:29:58 2005 +0200
+++ b/UIObjectView.st	Tue Jun 07 17:02:24 2005 +0200
@@ -491,17 +491,17 @@
 
         "/ handle any expose events (for subcomponents) before
         "/ redrawing the handles.
-        (self sensor hasExposeEventFor:nil) ifTrue:[^ self].
-
-        self selectionDo:[:aComponent |
-            aComponent withAllSubViewsDo:[:v |
-                v realized ifTrue:[
-                    self sensor flushExposeEventsFor:v.
-                    v exposeX:0 y:0 width:v width height:v height.
-                ]
-            ].
-            self showSelected:aComponent
-        ]
+"/        (self sensor hasExposeEventFor:nil) ifTrue:[^ self].
+"/
+"/        self selectionDo:[:aComponent |
+"/            aComponent withAllSubViewsDo:[:v |
+"/                v realized ifTrue:[
+"/                    self sensor flushExposeEventsFor:v.
+"/                    v exposeX:0 y:0 width:v width height:v height.
+"/                ]
+"/            ].
+"/            self showSelected:aComponent
+"/        ]
     ].
 
     "Modified: / 9.11.1998 / 12:50:34 / cg"
@@ -599,8 +599,23 @@
 !
 
 redrawX:nx y:ny width:nw height:nh
-    "ignore redraws - my components redraw themself
-    "
+    |redrawFrame|
+
+    redrawFrame := Rectangle left:nx top:ny width:nw height:nh.
+
+    self selectionDo:[:aComponent |
+        |anyHandleToRedraw|
+
+        anyHandleToRedraw := false.
+        self handlesOf:aComponent do:[:hRect :typeOfHandle |
+            (hRect intersects:redrawFrame) ifTrue:[        
+                anyHandleToRedraw := true.
+            ].
+        ].
+        anyHandleToRedraw ifTrue:[
+            self showSelected:aComponent
+        ]
+    ]
 !
 
 sizeChanged:how