--- a/EditTextView.st Tue Oct 30 16:52:17 2018 +0100
+++ b/EditTextView.st Tue Nov 06 12:23:08 2018 +0100
@@ -6881,8 +6881,9 @@
('Paste Box' pasteOrReplaceBox PasteBox ))
] ifFalse:[
mainItems := mainItems , #(
- ('Copy' copySelection Copy )
- ('Paste' pasteOrReplace Paste ))
+ ('Copy' copySelection Copy )
+ ('Paste' pasteOrReplace Paste )
+ ('Paste...' pasteOrReplaceFromHistory PasteFromHistory ))
].
mainItems := mainItems , #(
('-' )
@@ -7950,6 +7951,20 @@
]
"Modified: / 11-11-2017 / 12:52:31 / cg"
+!
+
+withSelfAndTextForPasteFromHistoryDo:aBlock
+ "common code for paste/replace from the copyBuffer history"
+
+ |sel|
+
+ (self checkModificationsAllowedFlashIfNot:true) ifFalse:[^ self].
+ sel := self getTextSelectionFromHistory.
+ sel notNil ifTrue:[
+ aBlock value:self value:sel.
+ ]
+
+ "Modified: / 11-11-2017 / 12:52:31 / cg"
! !
!EditTextView methodsFor:'private'!