Archived
1
0
Fork 0
forked from Mirror/Ryujinx
This repository has been archived on 2024-10-11. You can view files and clone it, but cannot push or open issues or pull requests.
jinx/Ryujinx.HLE/HOS/Kernel/KSynchronizationObject.cs

34 lines
804 B
C#
Raw Normal View History

using System.Collections.Generic;
namespace Ryujinx.HLE.HOS.Kernel
{
class KSynchronizationObject : KAutoObject
{
public LinkedList<KThread> WaitingThreads;
public KSynchronizationObject(Horizon System) : base(System)
{
WaitingThreads = new LinkedList<KThread>();
}
public LinkedListNode<KThread> AddWaitingThread(KThread Thread)
{
return WaitingThreads.AddLast(Thread);
}
public void RemoveWaitingThread(LinkedListNode<KThread> Node)
{
WaitingThreads.Remove(Node);
}
public virtual void Signal()
{
System.Synchronization.SignalObject(this);
}
public virtual bool IsSignaled()
{
return false;
}
}
}