diff options
author | Alexis211 <alexis211@gmail.com> | 2009-11-08 12:58:27 +0100 |
---|---|---|
committer | Alexis211 <alexis211@gmail.com> | 2009-11-08 12:58:27 +0100 |
commit | ec6a6922d074da4b64976282333e308deb39aeec (patch) | |
tree | 60d5e4a63095af75fc3ddae38021fa4c92ffd361 /Source/Kernel/VTManager | |
parent | 962b8e892ce060b9690a35b0bcf6bae9a882c330 (diff) | |
download | Melon-ec6a6922d074da4b64976282333e308deb39aeec.tar.gz Melon-ec6a6922d074da4b64976282333e308deb39aeec.zip |
Introduced PaperWork : our init/login manager.
Login with user=root;pass=admin or user=alexis211;pass=iamgod
Diffstat (limited to 'Source/Kernel/VTManager')
-rw-r--r-- | Source/Kernel/VTManager/VirtualTerminal-sc.proto.cpp | 25 | ||||
-rw-r--r-- | Source/Kernel/VTManager/VirtualTerminal.proto.cpp | 19 | ||||
-rw-r--r-- | Source/Kernel/VTManager/VirtualTerminal.proto.h | 2 |
3 files changed, 24 insertions, 22 deletions
diff --git a/Source/Kernel/VTManager/VirtualTerminal-sc.proto.cpp b/Source/Kernel/VTManager/VirtualTerminal-sc.proto.cpp index 0a4e14b..5506c74 100644 --- a/Source/Kernel/VTManager/VirtualTerminal-sc.proto.cpp +++ b/Source/Kernel/VTManager/VirtualTerminal-sc.proto.cpp @@ -1,4 +1,25 @@ #include "VirtualTerminal.proto.h" +#include <VirtualTerminal.iface.h> +#include <TaskManager/Task.ns.h> + +call_t VirtualTerminal::m_callTable[] = { + CALL1(VTIF_WRITEHEX, &VirtualTerminal::writeHexSC), + CALL2(VTIF_WRITEDEC, &VirtualTerminal::writeDecSC), + CALL1(VTIF_WRITE, &VirtualTerminal::writeSC), + CALL1(VTIF_PUT, &VirtualTerminal::putSC), + CALL1(VTIF_READLINE, &VirtualTerminal::readLineSC), + CALL1(VTIF_SETCOLOR, &VirtualTerminal::setColorSC), + CALL1(VTIF_SETCSRLINE, &VirtualTerminal::setCursorLineSC), + CALL1(VTIF_SETCSRCOL, &VirtualTerminal::setCursorColSC), + CALL0(VTIF_ISBOXED, &VirtualTerminal::isBoxedSC), + CALL0(0, 0) +}; + +u32int VirtualTerminal::scall(u8int wat, u32int a, u32int b, u32int c, u32int d) { + if (wat == VTIF_SGETPRINVT) return Task::currProcess()->getInVT()->resId(); + if (wat == VTIF_SGETPROUTVT) return Task::currProcess()->getOutVT()->resId(); + return (u32int) - 1; +} u32int VirtualTerminal::writeHexSC(u32int number) { writeHex(number); @@ -22,8 +43,8 @@ u32int VirtualTerminal::putSC(u32int code) { return 0; } -u32int VirtualTerminal::readLineSC() { - return readLine().serialize(); +u32int VirtualTerminal::readLineSC(u32int show) { + return readLine(show != 0).serialize(); } u32int VirtualTerminal::setColorSC(u32int x) { diff --git a/Source/Kernel/VTManager/VirtualTerminal.proto.cpp b/Source/Kernel/VTManager/VirtualTerminal.proto.cpp index 2587369..0079707 100644 --- a/Source/Kernel/VTManager/VirtualTerminal.proto.cpp +++ b/Source/Kernel/VTManager/VirtualTerminal.proto.cpp @@ -5,25 +5,6 @@ #include <VirtualTerminal.iface.h> -call_t VirtualTerminal::m_callTable[] = { - CALL1(VTIF_WRITEHEX, &VirtualTerminal::writeHexSC), - CALL2(VTIF_WRITEDEC, &VirtualTerminal::writeDecSC), - CALL1(VTIF_WRITE, &VirtualTerminal::writeSC), - CALL1(VTIF_PUT, &VirtualTerminal::putSC), - CALL0(VTIF_READLINE, &VirtualTerminal::readLineSC), - CALL1(VTIF_SETCOLOR, &VirtualTerminal::setColorSC), - CALL1(VTIF_SETCSRLINE, &VirtualTerminal::setCursorLineSC), - CALL1(VTIF_SETCSRCOL, &VirtualTerminal::setCursorColSC), - CALL0(VTIF_ISBOXED, &VirtualTerminal::isBoxedSC), - CALL0(0, 0) -}; - -u32int VirtualTerminal::scall(u8int wat, u32int a, u32int b, u32int c, u32int d) { - if (wat == VTIF_SGETPRINVT) return Task::currProcess()->getInVT()->resId(); - if (wat == VTIF_SGETPROUTVT) return Task::currProcess()->getOutVT()->resId(); - return (u32int) - 1; -} - VirtualTerminal::VirtualTerminal() : Ressource(VTIF_OBJTYPE, m_callTable), m_kbdMutex(false), m_kbdbuffMutex(false), m_kbdbuff() { } diff --git a/Source/Kernel/VTManager/VirtualTerminal.proto.h b/Source/Kernel/VTManager/VirtualTerminal.proto.h index 90fa88e..9c138ec 100644 --- a/Source/Kernel/VTManager/VirtualTerminal.proto.h +++ b/Source/Kernel/VTManager/VirtualTerminal.proto.h @@ -25,7 +25,7 @@ class VirtualTerminal : public Ressource { u32int writeDecSC(u32int, u32int); u32int writeSC(u32int); u32int putSC(u32int); - u32int readLineSC(); + u32int readLineSC(u32int); u32int setColorSC(u32int); u32int setCursorLineSC(u32int); u32int setCursorColSC(u32int); |