Thanks for the explanation but I do not get itI thought you wanted the inverse:Becauseshortcut1 := $a ctrl.
shortcut2 := $a ctrl shift
created different shortcuts.�You wrote:Why modifiers change receiver state instead of create new instance?And it is fully unexpected that I can not refactor it to:
shotcut2 := shortcut1 shiftahhh I got it.Because after that my shortcut1 become broken.
It was happen in TxTextMorph where selection and movement shortcuts created at same time
TxTextMorph>>moveEditorOn: aShortcut by: aSelector
���
��� self on: aShortcut do: [
��� ��� self moveEditorBy: aSelector withSelection: false ].
��� self on: selectionModeModifier + aShortcut� do: [
��� ��� self moveEditorBy: aSelector withSelection: true].
To fix it I add deep copy of given shortcut before modifier operation.>
> There is another example:
>
> shortcut := $a ctrl.
> self assert: shortcut == (KMModifier shift + shortcut)
>
> Yes. Such operation modified argument of message #+. What the crapp! Why it not returns new instance?
>
> I hope you agree to change this behaviour
>
>