diff options
author | Kartik K. Agaram <vc@akkartik.com> | 2024-08-31 18:59:23 -0700 |
---|---|---|
committer | Kartik K. Agaram <vc@akkartik.com> | 2024-08-31 18:59:23 -0700 |
commit | f98cdd14fd876f57a8dc753316fc27994242828f (patch) | |
tree | 5cf7dd0e0d7c7c87f2893eabe493d4e63530c1c8 /text.lua | |
parent | 5c8e3e96c8b852394cd2b0956d6e9bb0b6cc543d (diff) | |
download | lines.love-f98cdd14fd876f57a8dc753316fc27994242828f.tar.gz |
explicitly state when operations manage undo
Diffstat (limited to 'text.lua')
-rw-r--r-- | text.lua | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/text.lua b/text.lua index ac07903..14eb4b1 100644 --- a/text.lua +++ b/text.lua @@ -174,7 +174,7 @@ function Text.keychord_press(State, chord) schedule_save(State) elseif chord == 'backspace' then if State.selection1.line then - Text.delete_selection(State, State.left, State.right) + Text.delete_selection_and_record_undo_event(State) schedule_save(State) return end @@ -222,7 +222,7 @@ function Text.keychord_press(State, chord) schedule_save(State) elseif chord == 'delete' then if State.selection1.line then - Text.delete_selection(State, State.left, State.right) + Text.delete_selection_and_record_undo_event(State) schedule_save(State) return end |