Commit 5fe28f3c authored by Mathieu Maret's avatar Mathieu Maret

fix status line dsplay when scrolling

parent 2352c67b
core/irq_handler.o: core/irq_handler.c core/interrupt.h core/types.h \
core/io.h core/irq.h drivers/pic.h drivers/vga.h
......@@ -81,7 +81,7 @@ void vgaScrollUp(void)
VGA_WIDTH * sizeof(short));
}
for (int i = 0; i < VGA_WIDTH; i++) {
vga[(VGA_HEIGHT - 1) * VGA_WIDTH + i] = colorAttr;
vga[(VGA_HEIGHT - 2) * VGA_WIDTH + i] = colorAttr;
}
}
......@@ -97,7 +97,7 @@ void printChar(const char str)
if (str == '\n') {
line++;
col = 0;
if (line >= VGA_HEIGHT) {
if (line >= VGA_HEIGHT - 1) {
vgaScrollUp();
line--;
}
......@@ -122,7 +122,7 @@ void printChar(const char str)
col = 0;
line++;
}
if (line >= VGA_HEIGHT) {
if (line >= VGA_HEIGHT - 1) {
vgaScrollUp();
line--;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment