about summary refs log tree commit diff stats
diff options
context:
space:
mode:
authorKartik K. Agaram <vc@akkartik.com>2023-04-02 17:24:02 -0700
committerKartik K. Agaram <vc@akkartik.com>2023-04-02 17:24:02 -0700
commit95342345a827616c9f5fa7c914c02505d9e6ff4d (patch)
tree19d77fd64d379b5af80fe5fd22eccda1e0f5f7df
parent384fb2d19cf5879882426df9e31c77ad7e5bcc8d (diff)
downloadview.love-95342345a827616c9f5fa7c914c02505d9e6ff4d.tar.gz
change cursor bounds check slightly
This doesn't affect this fork directly, but it's a bad idea to assume
the _app_ is always going to be doing just what a particular subsystem
(here, the text editor in edit.lua+text.lua) is doing.
-rw-r--r--text.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/text.lua b/text.lua
index 709a676..758c572 100644
--- a/text.lua
+++ b/text.lua
@@ -936,7 +936,7 @@ end
 
 -- slightly expensive since it redraws the screen
 function Text.cursor_out_of_screen(State)
-  App.draw()
+  edit.draw(State)
   return State.cursor_y == nil
   -- this approach is cheaper and almost works, except on the final screen
   -- where file ends above bottom of screen