Update IHomeMenuFunctions.cs

This commit is contained in:
Ac_K 2018-04-21 21:17:16 +02:00 committed by GitHub
parent 48135623f3
commit 68dd2f4a88
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1,37 +1,36 @@
using Ryujinx.Core.OsHle.Handles;
using Ryujinx.Core.OsHle.Ipc;
using System.Collections.Generic;
namespace Ryujinx.Core.OsHle.Services.Am
{
class IHomeMenuFunctions : IpcService
{
private Dictionary<int, ServiceProcessRequest> m_Commands;
public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => m_Commands;
private KEvent ChannelEvent;
public IHomeMenuFunctions()
{
m_Commands = new Dictionary<int, ServiceProcessRequest>()
{
{ 10, RequestToGetForeground },
{ 21, GetPopFromGeneralChannelEvent }
using Ryujinx.Core.OsHle.Ipc;
using System.Collections.Generic;
namespace Ryujinx.Core.OsHle.Services.Am
{
class IHomeMenuFunctions : IpcService
{
private Dictionary<int, ServiceProcessRequest> m_Commands;
public override IReadOnlyDictionary<int, ServiceProcessRequest> Commands => m_Commands;
private KEvent ChannelEvent;
public IHomeMenuFunctions()
{
m_Commands = new Dictionary<int, ServiceProcessRequest>()
{
{ 10, RequestToGetForeground },
{ 21, GetPopFromGeneralChannelEvent }
};
ChannelEvent = new KEvent();
//TODO: We shouldn't be signaling this here.
ChannelEvent.WaitEvent.Set();
}
//ToDo: Signal this Event somewhere in future.
}
public long RequestToGetForeground(ServiceCtx Context)
{
Logging.Stub(LogClass.ServiceAm, "Stubbed");
return 0;
}
}
public long GetPopFromGeneralChannelEvent(ServiceCtx Context)
{
int Handle = Context.Process.HandleTable.OpenHandle(ChannelEvent);
@ -41,6 +40,6 @@ namespace Ryujinx.Core.OsHle.Services.Am
Logging.Stub(LogClass.ServiceAm, "Stubbed");
return 0;
}
}
}
}
}
}