Refactoring result codes (#731)
* refactoring result codes - Add a main enum who can handle some orphalin result codes and the default `ResultCode.Success` one. - Add sub-enum by services when it's needed. - Remove some empty line. - Recast all service calls to ResultCode. - Remove some unneeded static declaration. - Delete unused `NvHelper` class. * NvResult is back * Fix
This commit is contained in:
parent
4926f6523d
commit
4ad3936afd
147 changed files with 1413 additions and 1477 deletions
|
@ -18,16 +18,16 @@ namespace Ryujinx.HLE.HOS.Services.Am
|
|||
|
||||
[Command(10)]
|
||||
// RequestToGetForeground()
|
||||
public long RequestToGetForeground(ServiceCtx context)
|
||||
public ResultCode RequestToGetForeground(ServiceCtx context)
|
||||
{
|
||||
Logger.PrintStub(LogClass.ServiceAm);
|
||||
|
||||
return 0;
|
||||
return ResultCode.Success;
|
||||
}
|
||||
|
||||
[Command(21)]
|
||||
// GetPopFromGeneralChannelEvent() -> handle<copy>
|
||||
public long GetPopFromGeneralChannelEvent(ServiceCtx context)
|
||||
public ResultCode GetPopFromGeneralChannelEvent(ServiceCtx context)
|
||||
{
|
||||
if (context.Process.HandleTable.GenerateHandle(_channelEvent.ReadableEvent, out int handle) != KernelResult.Success)
|
||||
{
|
||||
|
@ -38,7 +38,7 @@ namespace Ryujinx.HLE.HOS.Services.Am
|
|||
|
||||
Logger.PrintStub(LogClass.ServiceAm);
|
||||
|
||||
return 0;
|
||||
return ResultCode.Success;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue