added: #atMenuItemLabeled:putSubmenu:visible:
authorClaus Gittinger <cg@exept.de>
Thu, 30 Jun 2011 10:39:10 +0200
changeset 4272 2023eba96b06
parent 4271 3ce604308987
child 4273 4e9e823f9e41
added: #atMenuItemLabeled:putSubmenu:visible:
PopUpMenu.st
--- a/PopUpMenu.st	Wed Jun 29 19:32:26 2011 +0200
+++ b/PopUpMenu.st	Thu Jun 30 10:39:10 2011 +0200
@@ -1064,6 +1064,19 @@
     menuView addItem:anItem
 !
 
+atMenuItemLabeled:aString putSubmenu:aMenu visible:visible
+    |idx|
+
+    idx := self indexOf:aString.
+    idx notNil ifTrue:[
+        visible ifTrue:[
+            self subMenuAt:aString put:(aMenu asOldStylePopUpMenuFor:self application).
+        ].
+    ].
+
+    "Created: / 30-06-2011 / 10:28:57 / cg"
+!
+
 indexOf:indexOrName
     "return the index of a submenu - or 0 if there is none"
 
@@ -1285,6 +1298,7 @@
     "Modified: 5.6.1996 / 17:08:30 / cg"
 ! !
 
+
 !PopUpMenu methodsFor:'deactivation'!
 
 hide
@@ -1640,10 +1654,6 @@
 
 !PopUpMenu class methodsFor:'documentation'!
 
-version
-    ^ '$Header: /cvs/stx/stx/libwidg/PopUpMenu.st,v 1.106 2009-10-24 13:43:51 cg Exp $'
-!
-
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libwidg/PopUpMenu.st,v 1.106 2009-10-24 13:43:51 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/PopUpMenu.st,v 1.107 2011-06-30 08:39:10 cg Exp $'
 ! !