1
0
Fork 0
mirror of https://github.com/Ryujinx/Ryujinx.git synced 2024-10-01 12:30:00 +02:00

acc/hid: Implement ListQualifiedUsers and SetTouchScreenConfiguration (#1555)

* acc/hid: Implement ListQualifiedUsers and SetTouchScreenConfiguration

* Fix symbols
This commit is contained in:
Ac_K 2020-09-20 06:32:58 +02:00 committed by GitHub
parent d0e36b7b19
commit 0158dc4db3
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 37 additions and 0 deletions

View file

@ -274,6 +274,31 @@ namespace Ryujinx.HLE.HOS.Services.Account.Acc
return ResultCode.Success; return ResultCode.Success;
} }
[Command(131)] // 6.0.0+
// ListOpenContextStoredUsers() -> array<nn::account::Uid, 0xa>
public ResultCode ListOpenContextStoredUsers(ServiceCtx context)
{
long outputPosition = context.Request.RecvListBuff[0].Position;
long outputSize = context.Request.RecvListBuff[0].Size;
MemoryHelper.FillWithZeros(context.Memory, outputPosition, (int)outputSize);
// TODO: This seems to write stored userids of the OpenContext in the buffer. We needs to determine them.
Logger.Stub?.PrintStub(LogClass.ServiceAcc);
return ResultCode.Success;
}
[Command(141)] // 6.0.0+
// ListQualifiedUsers() -> array<nn::account::Uid, 0xa>
public ResultCode ListQualifiedUsers(ServiceCtx context)
{
// TODO: Determine how users are "qualified". We assume all users are "qualified" for now.
return WriteUserList(context, context.Device.System.State.Account.GetAllUsers());
}
[Command(150)] // 6.0.0+ [Command(150)] // 6.0.0+
// IsUserAccountSwitchLocked() -> bool // IsUserAccountSwitchLocked() -> bool
public ResultCode IsUserAccountSwitchLocked(ServiceCtx context) public ResultCode IsUserAccountSwitchLocked(ServiceCtx context)

View file

@ -1501,5 +1501,17 @@ namespace Ryujinx.HLE.HOS.Services.Hid
return ResultCode.Success; return ResultCode.Success;
} }
[Command(1002)] // 9.0.0+
// SetTouchScreenConfiguration(nn::hid::TouchScreenConfigurationForNx, nn::applet::AppletResourceUserId)
public ResultCode SetTouchScreenConfiguration(ServiceCtx context)
{
long touchScreenConfigurationForNx = context.RequestData.ReadInt64();
long appletResourceUserId = context.RequestData.ReadInt64();
Logger.Stub?.PrintStub(LogClass.ServiceHid, new { appletResourceUserId, touchScreenConfigurationForNx });
return ResultCode.Success;
}
} }
} }