aboutsummaryrefslogtreecommitdiff
path: root/Ryujinx.HLE/HOS/Services/Nfp/IUser.cs
diff options
context:
space:
mode:
Diffstat (limited to 'Ryujinx.HLE/HOS/Services/Nfp/IUser.cs')
-rw-r--r--Ryujinx.HLE/HOS/Services/Nfp/IUser.cs60
1 files changed, 30 insertions, 30 deletions
diff --git a/Ryujinx.HLE/HOS/Services/Nfp/IUser.cs b/Ryujinx.HLE/HOS/Services/Nfp/IUser.cs
index 9e19e77f..f0dc825b 100644
--- a/Ryujinx.HLE/HOS/Services/Nfp/IUser.cs
+++ b/Ryujinx.HLE/HOS/Services/Nfp/IUser.cs
@@ -9,25 +9,25 @@ namespace Ryujinx.HLE.HOS.Services.Nfp
{
class IUser : IpcService
{
- private Dictionary<int, ServiceProcessRequest> _commands;
+ private Dictionary<int, ServiceProcessRequest> m_Commands;
- public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => _commands;
+ public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => m_Commands;
- private const HidControllerId NpadId = HidControllerId.ControllerPlayer1;
+ private const HidControllerId NpadId = HidControllerId.CONTROLLER_PLAYER_1;
- private State _state = State.NonInitialized;
+ private State State = State.NonInitialized;
- private DeviceState _deviceState = DeviceState.Initialized;
+ private DeviceState DeviceState = DeviceState.Initialized;
- private KEvent _activateEvent;
+ private KEvent ActivateEvent;
- private KEvent _deactivateEvent;
+ private KEvent DeactivateEvent;
- private KEvent _availabilityChangeEvent;
+ private KEvent AvailabilityChangeEvent;
- public IUser(Horizon system)
+ public IUser(Horizon System)
{
- _commands = new Dictionary<int, ServiceProcessRequest>
+ m_Commands = new Dictionary<int, ServiceProcessRequest>()
{
{ 0, Initialize },
{ 17, AttachActivateEvent },
@@ -38,85 +38,85 @@ namespace Ryujinx.HLE.HOS.Services.Nfp
{ 23, AttachAvailabilityChangeEvent }
};
- _activateEvent = new KEvent(system);
- _deactivateEvent = new KEvent(system);
- _availabilityChangeEvent = new KEvent(system);
+ ActivateEvent = new KEvent(System);
+ DeactivateEvent = new KEvent(System);
+ AvailabilityChangeEvent = new KEvent(System);
}
- public long Initialize(ServiceCtx context)
+ public long Initialize(ServiceCtx Context)
{
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
- _state = State.Initialized;
+ State = State.Initialized;
return 0;
}
- public long AttachActivateEvent(ServiceCtx context)
+ public long AttachActivateEvent(ServiceCtx Context)
{
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
- if (context.Process.HandleTable.GenerateHandle(_activateEvent.ReadableEvent, out int handle) != KernelResult.Success)
+ if (Context.Process.HandleTable.GenerateHandle(ActivateEvent.ReadableEvent, out int Handle) != KernelResult.Success)
{
throw new InvalidOperationException("Out of handles!");
}
- context.Response.HandleDesc = IpcHandleDesc.MakeCopy(handle);
+ Context.Response.HandleDesc = IpcHandleDesc.MakeCopy(Handle);;
return 0;
}
- public long AttachDeactivateEvent(ServiceCtx context)
+ public long AttachDeactivateEvent(ServiceCtx Context)
{
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
- if (context.Process.HandleTable.GenerateHandle(_deactivateEvent.ReadableEvent, out int handle) != KernelResult.Success)
+ if (Context.Process.HandleTable.GenerateHandle(DeactivateEvent.ReadableEvent, out int Handle) != KernelResult.Success)
{
throw new InvalidOperationException("Out of handles!");
}
- context.Response.HandleDesc = IpcHandleDesc.MakeCopy(handle);
+ Context.Response.HandleDesc = IpcHandleDesc.MakeCopy(Handle);
return 0;
}
- public long GetState(ServiceCtx context)
+ public long GetState(ServiceCtx Context)
{
- context.ResponseData.Write((int)_state);
+ Context.ResponseData.Write((int)State);
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
return 0;
}
- public long GetDeviceState(ServiceCtx context)
+ public long GetDeviceState(ServiceCtx Context)
{
- context.ResponseData.Write((int)_deviceState);
+ Context.ResponseData.Write((int)DeviceState);
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
return 0;
}
- public long GetNpadId(ServiceCtx context)
+ public long GetNpadId(ServiceCtx Context)
{
- context.ResponseData.Write((int)NpadId);
+ Context.ResponseData.Write((int)NpadId);
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
return 0;
}
- public long AttachAvailabilityChangeEvent(ServiceCtx context)
+ public long AttachAvailabilityChangeEvent(ServiceCtx Context)
{
Logger.PrintStub(LogClass.ServiceNfp, "Stubbed.");
- if (context.Process.HandleTable.GenerateHandle(_availabilityChangeEvent.ReadableEvent, out int handle) != KernelResult.Success)
+ if (Context.Process.HandleTable.GenerateHandle(AvailabilityChangeEvent.ReadableEvent, out int Handle) != KernelResult.Success)
{
throw new InvalidOperationException("Out of handles!");
}
- context.Response.HandleDesc = IpcHandleDesc.MakeCopy(handle);
+ Context.Response.HandleDesc = IpcHandleDesc.MakeCopy(Handle);
return 0;
}