feat(signindialog): implement close, get-result and get-status #560
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/560"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by Phi1ow on 2026-10-04T20:46:42Z.
What
sceSigninDialogClose,sceSigninDialogGetResultandsceSigninDialogGetStatuswere the threeremaining throwing stubs in
libSceSigninDialog; the other four exports already implement thecommon-dialog state machine. They now complete it:
sceSigninDialogGetStatus-> the status.sceSigninDialogClose-> ok, or0x80B80003when not initialized.sceSigninDialogGetResult-> onceFINISHED, reports the user-cancelled outcome (no PSNsign-in UI exists, so middleware takes its offline path); otherwise
0x80B80003/0x80B8000D(null) /0x80B80005(not finished).Uses the shared common-dialog status and error codes already defined in the file, and the
user-cancelled result value already used by
libSceWebBrowserDialog. Adds aCMakeLists.txtso the library can carry its guest test.
Tested
New test
core/libs/tests/GuestSigninDialog.cpp(registered asguest_signin_dialog) drivesthe full state machine including the three new functions.
Built with MinGW-w64 GCC 15.2.0 (the CI toolchain) on Windows 11;
ctest -R guest_signin_dialogpasses. On
mainthe three functions thrownot implemented, so the test aborts without thechange.
Checklist
main; no other open PR implements the same functionsNotImplemented_nid_no_patch); silent stubs are listed in TechnicalDebt.mdfiles or images added to the repository (attach them to this PR)Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-04T21:19:45Z.
Thanks. Reporting
USER_CANCELEDmatches main'slibSceWebBrowserDialog, and it's consistent withlibSceNpManager, which treats the user as signed out.sceSigninDialogOpen(which PPSA21564 calls) is unchanged.One small change:
sceSigninDialogGetResultzeroes 16 bytes of the caller's buffer, but nothing says the result struct is that size.sceWebBrowserDialogGetResultonly writes the leadingint32result. Could you do the same here, or point to where the 16 bytes come from? Please also add the dialog to the "Silent stubs" list in docs/dev/TechnicalDebt.md, since it finishes without any UI (the same line can cover #559).The CI run on this PR still needs approval; I'll check it once it has run.
Imported from boykopovar/AnyPS5. Originally posted by github-actions[bot] on 2026-10-04T22:29:52Z.
Progress report (
5fc8755→43eba76)📈 System libraries: 87.18% (+0.1%, +3 implemented functions)
✅ 3 implemented
sceSigninDialogClosesceSigninDialogGetResultsceSigninDialogGetStatusImported from boykopovar/AnyPS5. Originally posted by Phi1ow on 2026-10-04T22:34:24Z.
Done.
sceSigninDialogGetResultnow writes only the leadingint32result instead of zeroing 16 bytes, and added the dialog to the "Silent stubs" list.Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-04T23:43:55Z.
Thanks,
sceSigninDialogGetResultnow writes only the leading int32 and the test checks that the rest of the buffer is left alone, and the dialog is in the silent stubs list.guest_signin_dialogpasses here and CI is green. Ready to merge from my side (the TechnicalDebt line sits next to #558's and #559's, so a one-line rebase may be needed depending on order).Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-05T01:18:19Z.
#558 is on main now, and its libSceErrorDialog line sits where this one goes in the silent stubs list of docs/dev/TechnicalDebt.md, so this needs a one-line rebase that keeps both lines. #559 adds its line at the same spot, so whichever of the two lands second will need the same. Ready to merge from my side after that.
Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-06T21:20:53Z.
Are you still working on this? It still needs the one-line
docs/dev/TechnicalDebt.mdrebase from 10-05; the code was ready from my side then. If you'd rather not continue, please say so, and it can be closed.Imported from boykopovar/AnyPS5. Originally posted by Phi1ow on 2026-10-06T21:52:18Z.
Rebased, same as #559: kept the libSceErrorDialog line that's on main and added the libSceSigninDialog one. guest_signin_dialog passes here.
Imported from boykopovar/AnyPS5. Originally posted by Saalik on 2026-10-06T22:30:02Z.
Since the result-struct size came up earlier: the 16-byte figure comes from SharpProspero's SigninDialog.cs, which defines SceSigninDialogResult as an int32 result followed by three reserved int32s — the same on-device interop source the player invitation dialog's 40-byte layout is taken from in docs/dev/TechnicalDebt.md. No change suggested here; the leading-int32-only write is the safer ABI either way. Just leaving the provenance on record.
Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-06T22:42:26Z.
Thanks for the rebase. #559 is merged now, and both add their line next to libSceErrorDialog in the silent stubs list, so this branch conflicts with main in
docs/dev/TechnicalDebt.mdagain. Could you rebase once more? Nothing else needs to change.Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-07T15:47:06Z.
Review: CHANGES_REQUESTED
Thanks. Checked against the references before the rebase; one thing to fix (cc @oneandonlydean, since this was ready from your side):
0x80B8xxxx), but KytyPS5 (src/libs/dialog.cpp,SIGNIN_ERROR_*, and its SigninDialog test) uses SigninDialog's own codes:NOT_INITIALIZED0x81350001,ALREADY_INITIALIZED0x81350002,PARAM_INVALID0x81350003,INVALID_STATE0x81350005. SoExport.cpp:28and:34should return0x81350001,:350x81350003and:360x81350005(there's noNOT_FINISHED0x80B80005for this library). The existingInitialize/Terminate/Openreturns have the same problem, andGuestSigninDialog.cpp:21-24pins them. Could you switch the whole file to the SigninDialog codes in this PR? It's the same topic and your test already covers it.np.cpp,s_signin_dialog_close) both set the status toFINISHEDinsceSigninDialogClose, and KytyPS5's test checks thatInitialize→Close→UpdateStatusreturns 3. HereExport.cpp:28leaves the status unchanged. A test row for Close fromINITIALIZEDwould cover it.INVALID_STATEbeforePARAM_INVALID);Export.cpp:35-36does it the other way round.Build, ctest and the negative check (the test fails without the change) all pass here. Writing only the leading
int32of the result is right.Imported from boykopovar/AnyPS5. Originally posted by oneandonlydean on 2026-10-10T18:08:13Z.
Closing for now: the points from 2026-10-07 are still open. If you pick it back up, please comment here and it can be reopened.
Pull request closed