mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-21 12:32:40 +02:00
account: Added accountIsUserRegistrationRequestPermitted and accountTrySelectUserWithoutInteraction.
This commit is contained in:
parent
4078de1eff
commit
42aa0800f7
@ -74,6 +74,12 @@ Result accountGetLastOpenedUser(AccountUid *uid);
|
||||
/// Get an AccountProfile for the specified userId.
|
||||
Result accountGetProfile(AccountProfile* out, AccountUid uid);
|
||||
|
||||
/// IsUserRegistrationRequestPermitted
|
||||
Result accountIsUserRegistrationRequestPermitted(bool *out);
|
||||
|
||||
/// TrySelectUserWithoutInteraction
|
||||
Result accountTrySelectUserWithoutInteraction(AccountUid *uid, bool is_network_service_account_required);
|
||||
|
||||
/// Close the AccountProfile.
|
||||
void accountProfileClose(AccountProfile* profile);
|
||||
|
||||
|
@ -116,6 +116,21 @@ Result accountGetProfile(AccountProfile* out, AccountUid uid) {
|
||||
);
|
||||
}
|
||||
|
||||
Result accountIsUserRegistrationRequestPermitted(bool *out) {
|
||||
u64 pid_placeholder=0;
|
||||
u8 tmp=0;
|
||||
Result rc = serviceDispatchInOut(&g_accSrv, 50, pid_placeholder, tmp,
|
||||
.in_send_pid = true,
|
||||
);
|
||||
if (R_SUCCEEDED(rc) && out) *out = tmp & 1;
|
||||
return rc;
|
||||
}
|
||||
|
||||
Result accountTrySelectUserWithoutInteraction(AccountUid *uid, bool is_network_service_account_required) {
|
||||
u8 tmp=is_network_service_account_required!=0;
|
||||
return serviceDispatchInOut(&g_accSrv, 51, tmp, *uid);
|
||||
}
|
||||
|
||||
// IProfile
|
||||
|
||||
void accountProfileClose(AccountProfile* profile) {
|
||||
|
Loading…
Reference in New Issue
Block a user