mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-11-30 04:22:44 +00:00
loader: Fix 0 vs 1 confusion for column numbers
In two places we use '0' for a column number. However, the upper left hand corner of the screen is 1, 1. Fix those two confusions. Also, fix a comment that flipped the coordinates in a comment (I'm used to the vt100 convention where it's row, column (eg y, x)) and didn't notice the rest of the code uses x, y. Sponsored by: Netflix Differential Revision: https://reviews.freebsd.org/D46777
This commit is contained in:
parent
1b3fa1ac36
commit
604919c47f
@ -556,9 +556,9 @@ function menu.autoboot(delay)
|
||||
else
|
||||
-- Erase autoboot msg. While real VT100s
|
||||
-- wouldn't scroll when receiving a char with
|
||||
-- the cursor at (24, 79), bad emulators do.
|
||||
-- the cursor at (79, 24), bad emulators do.
|
||||
-- Avoid the issue by stopping at 79.
|
||||
screen.setcursor(0, y)
|
||||
screen.setcursor(1, y)
|
||||
printc(string.rep(" ", 79))
|
||||
screen.defcursor()
|
||||
return ch
|
||||
|
@ -32,7 +32,7 @@ local core = require("core")
|
||||
local screen = {}
|
||||
|
||||
-- Module exports
|
||||
screen.default_x = 0
|
||||
screen.default_x = 1
|
||||
screen.default_y = 25
|
||||
|
||||
function screen.clear()
|
||||
|
Loading…
Reference in New Issue
Block a user