mirror of
https://github.com/Ryujinx/Ryujinx.git
synced 2024-12-27 02:51:21 -08:00
560ccbeb2d
* Refactoring commands handling - Use Reflection to handle commands ID. - Add all symbols (from SwIPC so not all time accurate). - Re-sort some services commands methods. - Some cleanup. - Keep some empty constructor for consistency. * Fix order in IProfile
41 lines
992 B
C#
41 lines
992 B
C#
using Ryujinx.Common.Logging;
|
|
|
|
namespace Ryujinx.HLE.HOS.Services.Pctl
|
|
{
|
|
class IParentalControlService : IpcService
|
|
{
|
|
private bool _initialized = false;
|
|
|
|
private bool _needInitialize;
|
|
|
|
public IParentalControlService(bool needInitialize = true)
|
|
{
|
|
_needInitialize = needInitialize;
|
|
}
|
|
|
|
[Command(1)] // 4.0.0+
|
|
// Initialize()
|
|
public long Initialize(ServiceCtx context)
|
|
{
|
|
if (_needInitialize && !_initialized)
|
|
{
|
|
_initialized = true;
|
|
}
|
|
else
|
|
{
|
|
Logger.PrintWarning(LogClass.ServicePctl, "Service is already initialized!");
|
|
}
|
|
|
|
return 0;
|
|
}
|
|
|
|
[Command(1001)]
|
|
// CheckFreeCommunicationPermission()
|
|
public long CheckFreeCommunicationPermission(ServiceCtx context)
|
|
{
|
|
Logger.PrintStub(LogClass.ServicePctl);
|
|
|
|
return 0;
|
|
}
|
|
}
|
|
} |