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.
This commit is contained in:
Kartik K. Agaram 2023-04-02 17:24:02 -07:00
parent 384fb2d19c
commit 95342345a8
1 changed files with 1 additions and 1 deletions

View File

@ -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