aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/service/event.cpp
diff options
context:
space:
mode:
authorNarr the Reg <juangerman-13@hotmail.com>2024-01-31 10:25:28 -0600
committerGitHub <noreply@github.com>2024-01-31 10:25:28 -0600
commit7cc7d027f74b5bffc0b3f8f3a6c3110999c7cc4c (patch)
tree24b2ed412f2683c8460839778ea7761d052bc38f /src/core/hle/service/event.cpp
parent12e5293c73ce9965a6f73a8861d8b84f3f4ed615 (diff)
parent817d916233adcfb26814fde677e71d9825ce614c (diff)
Merge pull request #12760 from liamwhite/mp-am
am: rewrite for multiprocess support
Diffstat (limited to 'src/core/hle/service/event.cpp')
-rw-r--r--src/core/hle/service/event.cpp31
1 files changed, 31 insertions, 0 deletions
diff --git a/src/core/hle/service/event.cpp b/src/core/hle/service/event.cpp
new file mode 100644
index 000000000..375660d72
--- /dev/null
+++ b/src/core/hle/service/event.cpp
@@ -0,0 +1,31 @@
+// SPDX-FileCopyrightText: Copyright 2024 yuzu Emulator Project
+// SPDX-License-Identifier: GPL-2.0-or-later
+
+#include "core/hle/kernel/k_event.h"
+#include "core/hle/service/event.h"
+#include "core/hle/service/kernel_helpers.h"
+
+namespace Service {
+
+Event::Event(KernelHelpers::ServiceContext& ctx) {
+ m_event = ctx.CreateEvent("Event");
+}
+
+Event::~Event() {
+ m_event->GetReadableEvent().Close();
+ m_event->Close();
+}
+
+void Event::Signal() {
+ m_event->Signal();
+}
+
+void Event::Clear() {
+ m_event->Clear();
+}
+
+Kernel::KReadableEvent* Event::GetHandle() {
+ return &m_event->GetReadableEvent();
+}
+
+} // namespace Service