Workspace.st
changeset 4704 ea070cb320e5
parent 4703 2bbd9e98802d
child 4705 af96f6a12b41
--- a/Workspace.st	Sat Aug 31 00:53:52 2013 +0200
+++ b/Workspace.st	Sat Aug 31 01:04:45 2013 +0200
@@ -2331,33 +2331,37 @@
     v sensor
         pushUserEvent:#value
         for:[
-            v list:suggestions. 
-            v extent:completionView preferredExtentForContents.
-
-            v action:
-                [:index | 
-                    v notNil ifTrue:[
-                        v topView destroy. 
-                        v := nil
+            (v == completionView) ifTrue: [
+                v list:suggestions. 
+                v extent:completionView preferredExtentForContents.
+
+                v action:
+                    [:index | 
+                        v notNil ifTrue:[
+                            v topView destroy. 
+                            v := nil
+                        ].
+                        actions notNil ifTrue:[
+                            actions isBlock ifTrue:[
+                                actions value:index
+                            ] ifFalse:[
+                                (actions at:index) value
+                            ].
+                        ].
+                        editView sensor
+                            pushUserEvent:#value
+                            for:[
+                                self updateCompletionList
+                            ]
                     ].
-                    actions notNil ifTrue:[
-                        actions isBlock ifTrue:[
-                            actions value:index
-                        ] ifFalse:[
-                            (actions at:index) value
-                        ].
-                    ].
-                    editView sensor
-                        pushUserEvent:#value
-                        for:[
-                            self updateCompletionList
-                        ]
-                ].
-
-            v topView
-                resizeToFit;
-                "/ origin:movePos;
-                raise.
+
+                (v topView ~~ v) ifTrue:[
+                    v topView
+                        resizeToFit;
+                        "/ origin:movePos;
+                        raise.
+                ]
+            ]
         ]
 !
 
@@ -2374,10 +2378,10 @@
 !Workspace class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg/Workspace.st,v 1.277 2013-08-30 22:53:52 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/Workspace.st,v 1.278 2013-08-30 23:04:45 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libwidg/Workspace.st,v 1.277 2013-08-30 22:53:52 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/Workspace.st,v 1.278 2013-08-30 23:04:45 cg Exp $'
 ! !