summaryrefslogtreecommitdiff
path: root/Source/Applications/PaperWork
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Applications/PaperWork')
-rw-r--r--Source/Applications/PaperWork/Makefile2
-rw-r--r--Source/Applications/PaperWork/PaperWork.cpp13
2 files changed, 8 insertions, 7 deletions
diff --git a/Source/Applications/PaperWork/Makefile b/Source/Applications/PaperWork/Makefile
index d3203cf..8d079ec 100644
--- a/Source/Applications/PaperWork/Makefile
+++ b/Source/Applications/PaperWork/Makefile
@@ -4,7 +4,7 @@ CXX = g++
CXXFLAGS = -nostartfiles -nostdlib -ffreestanding -fno-exceptions -fno-rtti -I ../../Library/Common -I ../../Library/Interface -I ../../Library/Userland -D THIS_IS_MELON_USERLAND
LD = ld
-LDFLAGS = -T ../../Library/Link.ld -L ../../Library
+LDFLAGS = -T ../../Library/Link.ld -L ../../Library -Map Map.txt
Objects = PaperWork.o
OutFile = PaperWork
diff --git a/Source/Applications/PaperWork/PaperWork.cpp b/Source/Applications/PaperWork/PaperWork.cpp
index 4f9cb0e..15497e4 100644
--- a/Source/Applications/PaperWork/PaperWork.cpp
+++ b/Source/Applications/PaperWork/PaperWork.cpp
@@ -1,6 +1,7 @@
#include <App/ShellApp.proto.h>
#define DEFAULT_SHELL "/Applications/Shell/Shell.app"
+#define PAPERWORK_PATH "/System/Applications/PaperWork.app"
class PaperWork : public ShellApp {
public:
@@ -20,7 +21,7 @@ int PaperWork::run() {
if (act == "init") {
while (1) {
- Process p = Process::run("/System/Applications/PaperWork.app");
+ Process p = Process::run(PAPERWORK_PATH);
if (p.valid()) {
p.setInVT(invt);
p.setOutVT(outvt);
@@ -35,16 +36,16 @@ int PaperWork::run() {
outvt << "Logging in to Melon\n";
String user, pw;
while (1) {
- outvt << "Username: ";
- user = invt.readLine();
- outvt << "Password: ";
+ outvt << "Username: " << FLUSH;
+ user = invt.get();
+ outvt << "Password: " << FLUSH;
pw = invt.readLine(false);
if (!Process::get().authenticatePW(user, pw)) {
outvt << "Authentication failed.\n\n";
continue;
}
- outvt << "What shell to run [" << sFlag("shell") << "]? ";
- String sh = invt.readLine();
+ outvt << "What shell to run [" << sFlag("shell") << "]? "<< FLUSH;
+ String sh = invt.get();
if (sh == "") sh = sFlag("shell");
Process p = Process::run(sh);
if (p.valid()) {