summaryrefslogtreecommitdiffstats
path: root/src/core/hle/service/am/applets
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/hle/service/am/applets')
-rw-r--r--src/core/hle/service/am/applets/applet_software_keyboard.cpp20
-rw-r--r--src/core/hle/service/am/applets/applet_software_keyboard.h3
2 files changed, 15 insertions, 8 deletions
diff --git a/src/core/hle/service/am/applets/applet_software_keyboard.cpp b/src/core/hle/service/am/applets/applet_software_keyboard.cpp
index c89aa1bbf..1f21cee91 100644
--- a/src/core/hle/service/am/applets/applet_software_keyboard.cpp
+++ b/src/core/hle/service/am/applets/applet_software_keyboard.cpp
@@ -109,13 +109,18 @@ void SoftwareKeyboard::Execute() {
ShowNormalKeyboard();
}
-void SoftwareKeyboard::SubmitTextNormal(SwkbdResult result, std::u16string submitted_text) {
+void SoftwareKeyboard::SubmitTextNormal(SwkbdResult result, std::u16string submitted_text,
+ bool confirmed) {
if (complete) {
return;
}
if (swkbd_config_common.use_text_check && result == SwkbdResult::Ok) {
- SubmitForTextCheck(submitted_text);
+ if (confirmed) {
+ SubmitNormalOutputAndExit(result, submitted_text);
+ } else {
+ SubmitForTextCheck(submitted_text);
+ }
} else {
SubmitNormalOutputAndExit(result, submitted_text);
}
@@ -583,11 +588,12 @@ void SoftwareKeyboard::InitializeFrontendKeyboard() {
.disable_cancel_button{disable_cancel_button},
};
- frontend.InitializeKeyboard(false, std::move(initialize_parameters),
- [this](SwkbdResult result, std::u16string submitted_text) {
- SubmitTextNormal(result, submitted_text);
- },
- {});
+ frontend.InitializeKeyboard(
+ false, std::move(initialize_parameters),
+ [this](SwkbdResult result, std::u16string submitted_text, bool confirmed) {
+ SubmitTextNormal(result, submitted_text, confirmed);
+ },
+ {});
}
}
diff --git a/src/core/hle/service/am/applets/applet_software_keyboard.h b/src/core/hle/service/am/applets/applet_software_keyboard.h
index 6009c10c7..a0fddd965 100644
--- a/src/core/hle/service/am/applets/applet_software_keyboard.h
+++ b/src/core/hle/service/am/applets/applet_software_keyboard.h
@@ -36,8 +36,9 @@ public:
*
* @param result SwkbdResult enum
* @param submitted_text UTF-16 encoded string
+ * @param confirmed Whether the text has been confirmed after TextCheckResult::Confirm
*/
- void SubmitTextNormal(SwkbdResult result, std::u16string submitted_text);
+ void SubmitTextNormal(SwkbdResult result, std::u16string submitted_text, bool confirmed);
/**
* Submits the input text to the application.