mirror of
https://git.743378673.xyz/MeloNX/MeloNX.git
synced 2025-08-02 19:27:11 +02:00
Rename services with the official interface names
This commit is contained in:
parent
f15b1c76a1
commit
69e32e5bbc
29 changed files with 236 additions and 196 deletions
|
@ -1,180 +0,0 @@
|
|||
using Ryujinx.Core.Input;
|
||||
using Ryujinx.Core.OsHle.Ipc;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Ryujinx.Core.OsHle.Services.Hid
|
||||
{
|
||||
class ServiceHid : IpcService
|
||||
{
|
||||
private Dictionary<int, ServiceProcessRequest> m_Commands;
|
||||
|
||||
public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => m_Commands;
|
||||
|
||||
public ServiceHid()
|
||||
{
|
||||
m_Commands = new Dictionary<int, ServiceProcessRequest>()
|
||||
{
|
||||
{ 0, CreateAppletResource },
|
||||
{ 1, ActivateDebugPad },
|
||||
{ 11, ActivateTouchScreen },
|
||||
{ 21, ActivateMouse },
|
||||
{ 31, ActivateKeyboard },
|
||||
{ 66, StartSixAxisSensor },
|
||||
{ 100, SetSupportedNpadStyleSet },
|
||||
{ 101, GetSupportedNpadStyleSet },
|
||||
{ 102, SetSupportedNpadIdType },
|
||||
{ 103, ActivateNpad },
|
||||
{ 120, SetNpadJoyHoldType },
|
||||
{ 121, GetNpadJoyHoldType },
|
||||
{ 122, SetNpadJoyAssignmentModeSingleByDefault },
|
||||
{ 123, SetNpadJoyAssignmentModeSingle },
|
||||
{ 124, SetNpadJoyAssignmentModeDual },
|
||||
{ 125, MergeSingleJoyAsDualJoy },
|
||||
{ 200, GetVibrationDeviceInfo },
|
||||
{ 203, CreateActiveVibrationDeviceList },
|
||||
{ 206, SendVibrationValues }
|
||||
};
|
||||
}
|
||||
|
||||
public long CreateAppletResource(ServiceCtx Context)
|
||||
{
|
||||
MakeObject(Context, new IAppletResource(Context.Ns.Os.HidSharedMem));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long ActivateDebugPad(ServiceCtx Context)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long ActivateTouchScreen(ServiceCtx Context)
|
||||
{
|
||||
long AppletResourceUserId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long ActivateMouse(ServiceCtx Context)
|
||||
{
|
||||
long AppletResourceUserId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long ActivateKeyboard(ServiceCtx Context)
|
||||
{
|
||||
long AppletResourceUserId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long StartSixAxisSensor(ServiceCtx Context)
|
||||
{
|
||||
int Handle = Context.RequestData.ReadInt32();
|
||||
|
||||
long AppletResourceUserId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long GetSupportedNpadStyleSet(ServiceCtx Context)
|
||||
{
|
||||
Context.ResponseData.Write(0);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SetSupportedNpadStyleSet(ServiceCtx Context)
|
||||
{
|
||||
long Unknown0 = Context.RequestData.ReadInt64();
|
||||
long Unknown8 = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SetSupportedNpadIdType(ServiceCtx Context)
|
||||
{
|
||||
long Unknown = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long ActivateNpad(ServiceCtx Context)
|
||||
{
|
||||
long Unknown = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SetNpadJoyHoldType(ServiceCtx Context)
|
||||
{
|
||||
long Unknown0 = Context.RequestData.ReadInt64();
|
||||
long Unknown8 = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long GetNpadJoyHoldType(ServiceCtx Context)
|
||||
{
|
||||
Context.ResponseData.Write(0L);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SetNpadJoyAssignmentModeSingleByDefault(ServiceCtx Context)
|
||||
{
|
||||
HidControllerId HidControllerId = (HidControllerId)Context.RequestData.ReadInt32();
|
||||
long AppletUserResourseId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SetNpadJoyAssignmentModeSingle(ServiceCtx Context)
|
||||
{
|
||||
HidControllerId HidControllerId = (HidControllerId)Context.RequestData.ReadInt32();
|
||||
long AppletUserResourseId = Context.RequestData.ReadInt64();
|
||||
long NpadJoyDeviceType = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SetNpadJoyAssignmentModeDual(ServiceCtx Context)
|
||||
{
|
||||
HidControllerId HidControllerId = (HidControllerId)Context.RequestData.ReadInt32();
|
||||
long AppletUserResourseId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long MergeSingleJoyAsDualJoy(ServiceCtx Context)
|
||||
{
|
||||
long Unknown0 = Context.RequestData.ReadInt32();
|
||||
long Unknown8 = Context.RequestData.ReadInt32();
|
||||
long AppletUserResourseId = Context.RequestData.ReadInt64();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long GetVibrationDeviceInfo(ServiceCtx Context)
|
||||
{
|
||||
int VibrationDeviceHandle = Context.RequestData.ReadInt32();
|
||||
|
||||
Context.ResponseData.Write(0L); //VibrationDeviceInfoForIpc
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long CreateActiveVibrationDeviceList(ServiceCtx Context)
|
||||
{
|
||||
MakeObject(Context, new IActiveApplicationDeviceList());
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
public long SendVibrationValues(ServiceCtx Context)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue