summaryrefslogtreecommitdiff
path: root/Source/Kernel/Shell/KernelShell.class.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Kernel/Shell/KernelShell.class.cpp')
-rw-r--r--Source/Kernel/Shell/KernelShell.class.cpp12
1 files changed, 10 insertions, 2 deletions
diff --git a/Source/Kernel/Shell/KernelShell.class.cpp b/Source/Kernel/Shell/KernelShell.class.cpp
index 3d76ee0..4232cd9 100644
--- a/Source/Kernel/Shell/KernelShell.class.cpp
+++ b/Source/Kernel/Shell/KernelShell.class.cpp
@@ -15,8 +15,8 @@ u32int shellRun(void* ks) {
return ret;
}
-KernelShell::KernelShell(DirectoryNode* cwd) {
- m_vt = new ScrollableVT(15, 76, 200, SHELL_FGCOLOR, SHELL_BGCOLOR);
+void KernelShell::setup(DirectoryNode* cwd, VirtualTerminal *vt) {
+ m_vt = vt;
((ScrollableVT*)m_vt)->map(9);
Kbd::setFocus(m_vt);
m_cwd = cwd;
@@ -25,6 +25,14 @@ KernelShell::KernelShell(DirectoryNode* cwd) {
m_instances++;
}
+KernelShell::KernelShell(DirectoryNode* cwd, VirtualTerminal* vt) {
+ setup(cwd, vt);
+}
+
+KernelShell::KernelShell(DirectoryNode* cwd) {
+ setup(cwd, new ScrollableVT(15, 76, 200, SHELL_FGCOLOR, SHELL_BGCOLOR));
+}
+
KernelShell::~KernelShell() {
delete m_vt;
m_instances--;