boot/gui: Fix console restoring on exit
@@ -294,6 +294,9 @@ if File.exist?(SELECTIONS)
case event
when LVGL::EVENT::CLICKED
File.write("/run/boot/choice", selection["id"])
+
+ # Put back the console on the framebuffer
+ VTConsole.map_console(1)
exit 0
end
end
@@ -305,8 +308,4 @@ end
while true
LVGL::Hacks::LVTask.handle_tasks
sleep(1.0/REFRESH_RATE)
- # TODO : Allow exiting!
end
-
-# Put back the console on the framebuffer
-VTConsole.map_console(1)
