force imedialog to input "shadps4" as name . That way we can pass games that want username . temp solution till imgui dialog prepared

This commit is contained in:
georgemoralis 2024-07-17 20:32:14 +03:00
parent 439c0be9a6
commit 0ed9ea5b85
2 changed files with 15 additions and 6 deletions

View File

@ -9,6 +9,8 @@
namespace Libraries::ImeDialog {
static OrbisImeDialogStatus g_ime_dlg_status = OrbisImeDialogStatus::ORBIS_IME_DIALOG_STATUS_NONE;
int PS4_SYSV_ABI sceImeDialogAbort() {
LOG_ERROR(Lib_ImeDialog, "(STUBBED) called");
return ORBIS_OK;
@ -45,18 +47,25 @@ int PS4_SYSV_ABI sceImeDialogGetPanelSizeExtended() {
}
int PS4_SYSV_ABI sceImeDialogGetResult(OrbisImeDialogResult* result) {
result->endstatus = OrbisImeDialogEndStatus::ORBIS_IME_DIALOG_END_STATUS_OK;
LOG_ERROR(Lib_ImeDialog, "(STUBBED) called");
return ORBIS_OK;
}
int PS4_SYSV_ABI sceImeDialogGetStatus() {
LOG_ERROR(Lib_ImeDialog, "(STUBBED) called");
return ORBIS_OK;
if (g_ime_dlg_status == OrbisImeDialogStatus::ORBIS_IME_DIALOG_STATUS_RUNNING) {
return OrbisImeDialogStatus::ORBIS_IME_DIALOG_STATUS_FINISHED;
}
return g_ime_dlg_status;
}
int PS4_SYSV_ABI sceImeDialogInit(const OrbisImeDialogParam* param,
const OrbisImeParamExtended* extended) {
int PS4_SYSV_ABI sceImeDialogInit(OrbisImeDialogParam* param, OrbisImeParamExtended* extended) {
LOG_ERROR(Lib_ImeDialog, "(STUBBED) called");
const std::wstring_view text = L"shadPS4";
param->maxTextLength = text.size();
std::memcpy(param->inputTextBuffer, text.data(), text.size() * sizeof(wchar_t));
g_ime_dlg_status = OrbisImeDialogStatus::ORBIS_IME_DIALOG_STATUS_RUNNING;
return ORBIS_OK;
}
@ -82,6 +91,7 @@ int PS4_SYSV_ABI sceImeDialogSetPanelPosition() {
int PS4_SYSV_ABI sceImeDialogTerm() {
LOG_ERROR(Lib_ImeDialog, "(STUBBED) called");
g_ime_dlg_status = OrbisImeDialogStatus::ORBIS_IME_DIALOG_STATUS_NONE;
return ORBIS_OK;
}

View File

@ -174,8 +174,7 @@ int PS4_SYSV_ABI sceImeDialogGetPanelSize();
int PS4_SYSV_ABI sceImeDialogGetPanelSizeExtended();
int PS4_SYSV_ABI sceImeDialogGetResult(OrbisImeDialogResult* result);
/*OrbisImeDialogStatus*/ int PS4_SYSV_ABI sceImeDialogGetStatus();
int PS4_SYSV_ABI sceImeDialogInit(const OrbisImeDialogParam* param,
const OrbisImeParamExtended* extended);
int PS4_SYSV_ABI sceImeDialogInit(OrbisImeDialogParam* param, OrbisImeParamExtended* extended);
int PS4_SYSV_ABI sceImeDialogInitInternal();
int PS4_SYSV_ABI sceImeDialogInitInternal2();
int PS4_SYSV_ABI sceImeDialogInitInternal3();