allow for action with arg
authorClaus Gittinger <cg@exept.de>
Thu, 30 Jan 2003 16:39:19 +0100
changeset 2683 3c834e9ca478
parent 2682 1b5aeb99f26a
child 2684 91ac286733ac
allow for action with arg
MenuView.st
--- a/MenuView.st	Thu Jan 30 16:38:52 2003 +0100
+++ b/MenuView.st	Thu Jan 30 16:39:19 2003 +0100
@@ -1338,6 +1338,7 @@
             needResize := true
         ]
     ].
+
     subMenus at:i put:aPopUpMenu.
     aPopUpMenu notNil ifTrue:[
         aPopUpMenu device:device.
@@ -2148,15 +2149,19 @@
                                 theReceiver := receiver.
                             ].
 
-                            theSelector numArgs == 0 ifTrue:[
-                                theReceiver perform:theSelector
+                            theSelector isArray ifTrue:[
+                                theReceiver perform:(theSelector first) withArguments:(theSelector copyFrom:2)
                             ] ifFalse:[
-                                isCheck ifTrue:[
-                                    self redrawLine:idx.
-                                    val := checkOn.
-                                ].
-                            
-                                theReceiver perform:theSelector with:val 
+                                theSelector numArgs == 0 ifTrue:[
+                                    theReceiver perform:theSelector
+                                ] ifFalse:[
+                                    isCheck ifTrue:[
+                                        self redrawLine:idx.
+                                        val := checkOn.
+                                    ].
+                                
+                                    theReceiver perform:theSelector with:val 
+                                ]
                             ]
                         ]
 
@@ -2770,5 +2775,5 @@
 !MenuView class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg/MenuView.st,v 1.138 2002-08-19 16:25:14 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/MenuView.st,v 1.139 2003-01-30 15:39:19 cg Exp $'
 ! !