1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-30 15:18:11 +00:00

TTY: Reset VGA start row when setting graphical TTY

This was causing the screen (on a real machine) to be split in half.
This commit is contained in:
Jesse Buhagiar 2020-02-18 21:46:52 +11:00 committed by Andreas Kling
parent 94ed183774
commit 35ba4bf005
2 changed files with 9 additions and 1 deletions

View file

@ -65,6 +65,14 @@ void VirtualConsole::initialize()
s_active_console = -1; s_active_console = -1;
} }
void VirtualConsole::set_graphical(bool graphical)
{
if (graphical)
set_vga_start_row(0);
m_graphical = graphical;
}
VirtualConsole::VirtualConsole(unsigned index, InitialContents initial_contents) VirtualConsole::VirtualConsole(unsigned index, InitialContents initial_contents)
: TTY(4, index) : TTY(4, index)
, m_index(index) , m_index(index)

View file

@ -49,7 +49,7 @@ public:
static void initialize(); static void initialize();
bool is_graphical() { return m_graphical; } bool is_graphical() { return m_graphical; }
void set_graphical(bool graphical) { m_graphical = graphical; } void set_graphical(bool graphical);
private: private:
// ^KeyboardClient // ^KeyboardClient