EditField.st
changeset 3702 30f5a2efe531
parent 3648 7a959d9db34f
child 3703 5463ea3878b0
--- a/EditField.st	Thu Sep 04 11:57:44 2008 +0200
+++ b/EditField.st	Wed Sep 10 12:48:31 2008 +0200
@@ -1798,56 +1798,6 @@
 
 !EditField methodsFor:'initialization & release'!
 
-editMenu
-    "return a popUpMenu for the receiver"
-
-    <resource: #keyboard ( #Accept #Copy #Cut #Paste ) >
-    <resource: #programMenu>
-
-    |items m|
-
-    self isReadOnly == true ifTrue:[
-        items := #(
-                ('Copy'   copySelection  Copy  )
-                )
-    ] ifFalse:[
-        items := #(
-                    ('Cut'    cut            Cut   )
-                    ('Copy'   copySelection  Copy  )
-                    ('Paste'  pasteOrReplace Paste )
-                   ).
-        (acceptAction notNil 
-        or:[model notNil and:[changeMsg notNil]]) ifTrue:[
-            immediateAccept ifFalse:[
-                items := items , #(
-                                        ('-'                     )
-                                        ('Accept'  accept  Accept)
-                                    ).
-            ].
-        ].
-    ].
-
-    m := PopUpMenu itemList:items resources:resources.
-
-    passwordCharacter notNil ifTrue:[
-        m disable:#copySelection
-    ].
-
-    self hasSelectionForCopy ifFalse:[
-        m disable:#copySelection
-    ].
-    self hasSelection ifFalse:[
-        m disable:#cut
-    ].
-    (enabled not or:[self isReadOnly]) ifTrue:[
-        m disableAll:#(cut pasteOrReplace accept)
-    ].
-
-    ^ m
-
-    "Modified: / 28.7.1998 / 11:35:41 / cg"
-!
-
 initStyle
     "setup viewStyle specifics"
 
@@ -1904,6 +1854,58 @@
     "Modified: / 28.6.1999 / 18:08:17 / cg"
 ! !
 
+!EditField methodsFor:'menu actions'!
+
+editMenu
+    "return a popUpMenu for the receiver"
+
+    <resource: #keyboard ( #Accept #Copy #Cut #Paste ) >
+    <resource: #programMenu>
+
+    |items m|
+
+    self isReadOnly == true ifTrue:[
+        items := #(
+                ('Copy'   copySelection  Copy  )
+                )
+    ] ifFalse:[
+        items := #(
+                    ('Cut'    cut            Cut   )
+                    ('Copy'   copySelection  Copy  )
+                    ('Paste'  pasteOrReplace Paste )
+                   ).
+        (acceptAction notNil 
+        or:[model notNil and:[changeMsg notNil]]) ifTrue:[
+            immediateAccept ifFalse:[
+                items := items , #(
+                                        ('-'                     )
+                                        ('Accept'  accept  Accept)
+                                    ).
+            ].
+        ].
+    ].
+
+    m := PopUpMenu itemList:items resources:resources.
+
+    passwordCharacter notNil ifTrue:[
+        m disable:#copySelection
+    ].
+
+    self hasSelectionForCopy ifFalse:[
+        m disable:#copySelection
+    ].
+    self hasSelection ifFalse:[
+        m disable:#cut
+    ].
+    (enabled not or:[self isReadOnly]) ifTrue:[
+        m disableAll:#(cut pasteOrReplace accept)
+    ].
+
+    ^ m
+
+    "Modified: / 28.7.1998 / 11:35:41 / cg"
+! !
+
 !EditField methodsFor:'private'!
 
 argForChangeMessage
@@ -2202,5 +2204,5 @@
 !EditField class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libwidg/EditField.st,v 1.192 2008-06-23 16:51:00 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libwidg/EditField.st,v 1.193 2008-09-10 10:48:31 cg Exp $'
 ! !