mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:17:44 +00:00
Remove remains of the old "panel" task.
...and grow the console by 1 row! :^)
This commit is contained in:
parent
d90d125dfe
commit
3676214a62
5 changed files with 4 additions and 53 deletions
|
@ -37,7 +37,7 @@ void Console::putChar(char ch)
|
||||||
switch (ch) {
|
switch (ch) {
|
||||||
case '\n':
|
case '\n':
|
||||||
m_cursorColumn = 0;
|
m_cursorColumn = 0;
|
||||||
if (m_cursorRow == (m_rows - 2)) {
|
if (m_cursorRow == (m_rows - 1)) {
|
||||||
vga_scroll_up();
|
vga_scroll_up();
|
||||||
} else {
|
} else {
|
||||||
++m_cursorRow;
|
++m_cursorRow;
|
||||||
|
@ -50,7 +50,7 @@ void Console::putChar(char ch)
|
||||||
|
|
||||||
++m_cursorColumn;
|
++m_cursorColumn;
|
||||||
if (m_cursorColumn >= m_columns) {
|
if (m_cursorColumn >= m_columns) {
|
||||||
if (m_cursorRow == (m_rows - 2)) {
|
if (m_cursorRow == (m_rows - 1)) {
|
||||||
vga_scroll_up();
|
vga_scroll_up();
|
||||||
} else {
|
} else {
|
||||||
++m_cursorRow;
|
++m_cursorRow;
|
||||||
|
|
|
@ -28,7 +28,6 @@ public:
|
||||||
Handle(AnyHandle) : m_data(0xffffffff) { }
|
Handle(AnyHandle) : m_data(0xffffffff) { }
|
||||||
|
|
||||||
enum KernelTask {
|
enum KernelTask {
|
||||||
PanelTask = 4001,
|
|
||||||
DiskTask = 4002,
|
DiskTask = 4002,
|
||||||
FileSystemTask = 4003,
|
FileSystemTask = 4003,
|
||||||
MotdTask = 4004,
|
MotdTask = 4004,
|
||||||
|
|
|
@ -14,7 +14,6 @@ KERNEL_OBJS = \
|
||||||
PIC.o \
|
PIC.o \
|
||||||
Syscall.o \
|
Syscall.o \
|
||||||
DataBuffer.o \
|
DataBuffer.o \
|
||||||
panel.o \
|
|
||||||
Disk.o \
|
Disk.o \
|
||||||
Userspace.o \
|
Userspace.o \
|
||||||
IDEDiskDevice.o \
|
IDEDiskDevice.o \
|
||||||
|
|
|
@ -10,8 +10,8 @@ PRIVATE BYTE current_attr = 0x07;
|
||||||
|
|
||||||
void vga_scroll_up()
|
void vga_scroll_up()
|
||||||
{
|
{
|
||||||
memcpy(vga_mem, vga_mem + 160, 160 * 23);
|
memcpy(vga_mem, vga_mem + 160, 160 * 24);
|
||||||
memset(vga_mem + (160 * 23), 0, 160);
|
memset(vga_mem + (160 * 24), 0, 160);
|
||||||
}
|
}
|
||||||
|
|
||||||
void vga_putch_at(byte row, byte column, byte ch)
|
void vga_putch_at(byte row, byte column, byte ch)
|
||||||
|
|
|
@ -1,47 +0,0 @@
|
||||||
#include "types.h"
|
|
||||||
#include "Task.h"
|
|
||||||
#include "VGA.h"
|
|
||||||
#include "system.h"
|
|
||||||
#include "i386.h"
|
|
||||||
#include "i8253.h"
|
|
||||||
#include "kmalloc.h"
|
|
||||||
|
|
||||||
PUBLIC void panel_main() NORETURN;
|
|
||||||
|
|
||||||
PUBLIC void
|
|
||||||
panel_main()
|
|
||||||
{
|
|
||||||
WORD c;
|
|
||||||
BYTE a;
|
|
||||||
|
|
||||||
for( ;; )
|
|
||||||
{
|
|
||||||
continue;
|
|
||||||
/* HACK: Avoid getting interrupted while painting since
|
|
||||||
* that could lead to fugly artifacts ;P */
|
|
||||||
cli();
|
|
||||||
|
|
||||||
c = vga_get_cursor();
|
|
||||||
a = vga_get_attr();
|
|
||||||
|
|
||||||
vga_set_attr( 0x17 );
|
|
||||||
vga_set_cursor( 80 * 24 );
|
|
||||||
|
|
||||||
kprintf(
|
|
||||||
" Uptime: %u -- %u tasks (%u blocked) kmalloc: %u/%u ",
|
|
||||||
system.uptime / TICKS_PER_SECOND,
|
|
||||||
system.nprocess,
|
|
||||||
system.nblocked,
|
|
||||||
sum_alloc,
|
|
||||||
sum_free
|
|
||||||
);
|
|
||||||
|
|
||||||
vga_set_attr( a );
|
|
||||||
vga_set_cursor( c );
|
|
||||||
|
|
||||||
/* HACK cont.d */
|
|
||||||
sti();
|
|
||||||
|
|
||||||
sleep( 1 * TICKS_PER_SECOND );
|
|
||||||
}
|
|
||||||
}
|
|
Loading…
Add table
Add a link
Reference in a new issue