about summary refs log tree commit diff stats
path: root/run.lua
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2023-03-23 21:00:09 -0700
committerKartik K. Agaram <vc@akkartik.com>2023-03-23 21:00:09 -0700
commit99faf61abbd90f3d5da40788adc43c2883beb470 (patch)
treec305911012de36605bbf62ccf0d2b5022c314922 /run.lua
parent609f0b2fc850e9e6da8eb92b9d855c4e6ccf863b (diff)
downloadlines.love-99faf61abbd90f3d5da40788adc43c2883beb470.tar.gz
mouse wheel support
Diffstat (limited to 'run.lua')
-rw-r--r--run.lua5
1 files changed, 5 insertions, 0 deletions
diff --git a/run.lua b/run.lua
index 28516f6..ae78d9b 100644
--- a/run.lua
+++ b/run.lua
@@ -163,6 +163,11 @@ function run.mouse_release(x,y, mouse_button)
   return edit.mouse_release(Editor_state, x,y, mouse_button)
 end
 
+function run.mouse_wheel_move(x,y)
+  Cursor_time = 0  -- ensure cursor is visible immediately after it moves
+  return edit.mouse_wheel_move(Editor_state, x,y)
+end
+
 function run.text_input(t)
   Cursor_time = 0  -- ensure cursor is visible immediately after it moves
   return edit.text_input(Editor_state, t)