Resolve nits
This commit is contained in:
parent
e4a0dc42fc
commit
9182c4c806
5 changed files with 39 additions and 31 deletions
|
@ -22,7 +22,7 @@ namespace Ryujinx.HLE.HOS.Applets
|
|||
return (IApplet)Activator.CreateInstance(appletClass, system);
|
||||
}
|
||||
|
||||
return new StubApplet();
|
||||
throw new NotImplementedException($"{applet} applet is not implemented.");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
using Ryujinx.HLE.HOS.Services.Am.AppletAE;
|
||||
using Ryujinx.HLE.HOS.Services.Account.Acc;
|
||||
using Ryujinx.HLE.HOS.Services.Am.AppletAE;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.IO;
|
||||
|
@ -57,14 +58,13 @@ namespace Ryujinx.HLE.HOS.Applets
|
|||
|
||||
private byte[] BuildResponse()
|
||||
{
|
||||
var currentUser = _system.State.Account.LastOpenedUser;
|
||||
UserProfile currentUser = _system.State.Account.LastOpenedUser;
|
||||
|
||||
using (var ms = new MemoryStream())
|
||||
using (MemoryStream ms = new MemoryStream())
|
||||
{
|
||||
var writer = new BinaryWriter(ms);
|
||||
BinaryWriter writer = new BinaryWriter(ms);
|
||||
|
||||
// Result (0 = Success, 2 = Failure)
|
||||
writer.Write(0UL);
|
||||
writer.Write((ulong)PlayerSelectResult.Success);
|
||||
// UserID Low (long) High (long)
|
||||
currentUser.UserId.Write(writer);
|
||||
|
||||
|
|
|
@ -0,0 +1,8 @@
|
|||
namespace Ryujinx.HLE.HOS.Applets
|
||||
{
|
||||
enum PlayerSelectResult : ulong
|
||||
{
|
||||
Success = 0,
|
||||
Failure = 2
|
||||
}
|
||||
}
|
|
@ -69,14 +69,14 @@ namespace Ryujinx.HLE.HOS.Services.Am.AppletAE.AllSystemAppletProxiesService.Lib
|
|||
// PopOutData() -> object<nn::am::service::IStorage>
|
||||
public ResultCode PopOutData(ServiceCtx context)
|
||||
{
|
||||
var result = _applet.PopOutData(out IStorage storage);
|
||||
ResultCode result = (ResultCode)_applet.PopOutData(out IStorage storage);
|
||||
|
||||
if(storage != null)
|
||||
if (result == ResultCode.Success && storage != null)
|
||||
{
|
||||
MakeObject(context, storage);
|
||||
}
|
||||
|
||||
return (ResultCode)result;
|
||||
return result;
|
||||
}
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue