about summary refs log tree commit diff stats
path: root/source_text.lua
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2024-08-31 18:59:23 -0700
committerKartik K. Agaram <vc@akkartik.com>2024-08-31 18:59:23 -0700
commitf98cdd14fd876f57a8dc753316fc27994242828f (patch)
tree5cf7dd0e0d7c7c87f2893eabe493d4e63530c1c8 /source_text.lua
parent5c8e3e96c8b852394cd2b0956d6e9bb0b6cc543d (diff)
downloadview.love-f98cdd14fd876f57a8dc753316fc27994242828f.tar.gz
explicitly state when operations manage undo
Diffstat (limited to 'source_text.lua')
-rw-r--r--source_text.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/source_text.lua b/source_text.lua
index 76e9045..9125cb0 100644
--- a/source_text.lua
+++ b/source_text.lua
@@ -248,7 +248,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
@@ -296,7 +296,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