diff --git a/src/main.rs b/src/main.rs index a886e26aba..bb693f77b8 100644 --- a/src/main.rs +++ b/src/main.rs @@ -221,6 +221,11 @@ fn select_mode( let mut countdown = AUTOBOOT_SECONDS; let mut countdown_active = true; + // Capture the countdown line's row now, so the in-loop countdown updates it + // in place. Deriving it from list_y with a fixed offset landed one row too + // low (on the "Use Up/Down" line), leaving this header as a stale second + // "Autobooting in X seconds" copy above the live one. + let countdown_y = os.get_text_position().1; os.set_text_color(TextColor::Yellow); println!( " Autobooting in {} seconds (press any key to cancel)", @@ -240,7 +245,6 @@ fn select_mode( println!(); let (list_x, list_y) = os.get_text_position(); - let countdown_y = list_y.saturating_sub(4); loop { for (i, entry) in entries.iter().enumerate() {