From a8e042fd30b09a550e7dc53f8de802a3d14822c0 Mon Sep 17 00:00:00 2001 From: citra-swkbd <32505789+citra-swkbd@users.noreply.github.com> Date: Wed, 4 Oct 2017 09:24:21 -0500 Subject: [PATCH] swkbd: basic implementation --- src/core/hle/applets/swkbd.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/src/core/hle/applets/swkbd.cpp b/src/core/hle/applets/swkbd.cpp index 0bc471a3a..f6c6c2f71 100644 --- a/src/core/hle/applets/swkbd.cpp +++ b/src/core/hle/applets/swkbd.cpp @@ -14,7 +14,7 @@ #include "core/hle/service/gsp_gpu.h" #include "core/hle/service/hid/hid.h" #include "core/memory.h" - +using namespace std; //////////////////////////////////////////////////////////////////////////////////////////////////// namespace HLE { @@ -77,7 +77,10 @@ void SoftwareKeyboard::Update() { // TODO(Subv): Handle input using the touch events from the HID module // TODO(Subv): Remove this hardcoded text - std::u16string text = Common::UTF8ToUTF16("Citra"); + string input = "Citra"; + cout << "Type the text you want to send to the application:"; + std::getline(std::cin, input); + std::u16string text = Common::UTF8ToUTF16(input); memcpy(text_memory->GetPointer(), text.c_str(), text.length() * sizeof(char16_t)); // TODO(Subv): Ask for input and write it to the shared memory