From 7945094deb5cb6bac24a2ec96a4cc3bc0d64b6c8 Mon Sep 17 00:00:00 2001 From: dam Date: Mon, 27 Nov 2023 00:26:13 +0000 Subject: Reordered the start/stop sequences. --- TUI/module.jai | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/TUI/module.jai b/TUI/module.jai index 2774240..8f5c69a 100644 --- a/TUI/module.jai +++ b/TUI/module.jai @@ -176,8 +176,8 @@ start :: () { input_string.count = 0; input_override = xx Keys.None; - OS_prepare_terminal(); write_strings(Commands.HideCursor, Commands.SaveCursorPosition, Commands.EnterAlternateBuffer, Commands.SetUTF8); + OS_prepare_terminal(); initialized = true; } @@ -186,8 +186,8 @@ stop :: () { if initialized == false return; initialized = false; - write_strings(Commands.EnterMainBuffer, Commands.RestoreCursorPosition, Commands.ShowCursor); OS_reset_terminal(); + write_strings(Commands.EnterMainBuffer, Commands.RestoreCursorPosition, Commands.ShowCursor); } flush_input :: () { -- cgit v1.2.3