mirror of
https://github.com/Fennix-Project/Kernel.git
synced 2025-07-11 23:39:20 +00:00
Add SetDoNotScroll
This commit is contained in:
@ -188,6 +188,9 @@ namespace Video
|
||||
return;
|
||||
}
|
||||
|
||||
if (this->Buffers[Index].DoNotScroll)
|
||||
return;
|
||||
|
||||
if (Lines == 0)
|
||||
return;
|
||||
|
||||
@ -201,6 +204,17 @@ namespace Video
|
||||
}
|
||||
}
|
||||
|
||||
void Display::SetDoNotScroll(bool Value, int Index)
|
||||
{
|
||||
if (unlikely(this->Buffers[Index].Checksum != 0xDEAD))
|
||||
{
|
||||
debug("Invalid buffer %d", Index);
|
||||
return;
|
||||
}
|
||||
|
||||
this->Buffers[Index].DoNotScroll = Value;
|
||||
}
|
||||
|
||||
char Display::Print(char Char, int Index, bool WriteToUART)
|
||||
{
|
||||
if (unlikely(this->Buffers[Index].Checksum != 0xDEAD))
|
||||
@ -302,8 +316,11 @@ namespace Video
|
||||
|
||||
if (this->Buffers[Index].CursorY + FontHeight >= this->Buffers[Index].Height)
|
||||
{
|
||||
this->Buffers[Index].CursorY -= FontHeight;
|
||||
this->Scroll(Index, 1);
|
||||
if (!this->Buffers[Index].DoNotScroll)
|
||||
{
|
||||
this->Buffers[Index].CursorY -= FontHeight;
|
||||
this->Scroll(Index, 1);
|
||||
}
|
||||
}
|
||||
|
||||
switch (this->CurrentFont->GetInfo().Type)
|
||||
|
Reference in New Issue
Block a user