added: #label:value:argument:
authorClaus Gittinger <cg@exept.de>
Thu, 26 Apr 2012 12:36:26 +0200
changeset 3003 e2177537ecb8
parent 3002 a6acab3dbdea
child 3004 ea33c918e116
added: #label:value:argument: comment/format in: #label:choice:choiceValue: #label:value: #label:value:enabled: changed: #label: #labeled: #separator
MenuItem.st
--- a/MenuItem.st	Wed Apr 25 21:46:59 2012 +0200
+++ b/MenuItem.st	Thu Apr 26 12:36:26 2012 +0200
@@ -64,33 +64,49 @@
 label:aString
     "create and return a new menuItem, given a label string"
 
-    ^ self new label:aString
+    ^ self new 
+        label:aString;
+        yourself
 
-    "Modified: / 4.8.1998 / 17:33:13 / cg"
-    "Created: / 14.8.1998 / 19:19:14 / cg"
+    "Created: / 14-08-1998 / 19:19:14 / cg"
 !
 
 label:labelString choice:choiceAspect choiceValue:selectorOrValue
     "create and return a new menuItem, given its label and choice/value.
      This will create a Radio-Button-like item."
 
-    ^ (self new) label:labelString; choice:choiceAspect; choiceValue:selectorOrValue; yourself
+    ^ (self new) 
+        label:labelString; choice:choiceAspect; choiceValue:selectorOrValue; 
+        yourself
+
+    "Modified (format): / 26-04-2012 / 12:06:41 / cg"
 !
 
 label:labelString value:selectorOrValue
     "create and return a new menuItem, given its label and value"
 
-    ^ (self new) label:labelString; value:selectorOrValue; yourself
+    ^ (self new) 
+        label:labelString; value:selectorOrValue; 
+        yourself
+
+    "Created: / 04-08-1998 / 17:34:18 / cg"
+!
 
-    "Created: / 4.8.1998 / 17:34:18 / cg"
+label:labelString value:selectorOrValue argument:messageArg
+    "create and return a new menuItem, given its label and value"
+
+    ^ (self new) 
+        label:labelString; value:selectorOrValue; argument:messageArg;
+        yourself
+
+    "Created: / 26-04-2012 / 12:06:34 / cg"
 !
 
 label:labelString value:selectorOrValue enabled:enabledHolder
     "create and return a new menuItem, given its label and value"
 
     ^ (self new) 
-        label:labelString; 
-        value:selectorOrValue; 
+        label:labelString; value:selectorOrValue; 
         enabled:enabledHolder;
         yourself
 
@@ -100,15 +116,21 @@
 labeled:aString
     "create and return a new menuItem, given a label string"
 
-    ^ self new label:aString
+    ^ self new 
+        label:aString;
+        yourself
 
-    "Modified: / 4.8.1998 / 17:33:13 / cg"
+    "Modified: / 26-04-2012 / 12:07:12 / cg"
 !
 
 separator
     "create and return a new menuItem for a separator"
 
-    ^ self new label:'-'; translateLabel:false
+    ^ self new 
+        label:'-'; translateLabel:false;
+        yourself
+
+    "Modified: / 26-04-2012 / 12:07:04 / cg"
 ! !
 
 !MenuItem class methodsFor:'constants'!
@@ -1018,9 +1040,9 @@
 !MenuItem class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libview2/MenuItem.st,v 1.96 2012-02-14 14:17:29 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview2/MenuItem.st,v 1.97 2012-04-26 10:36:26 cg Exp $'
 !
 
 version_CVS
-    ^ '$Header: /cvs/stx/stx/libview2/MenuItem.st,v 1.96 2012-02-14 14:17:29 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libview2/MenuItem.st,v 1.97 2012-04-26 10:36:26 cg Exp $'
 ! !