diff options
author | Narr the Reg <juangerman-13@hotmail.com> | 2024-01-05 03:37:43 +0100 |
---|---|---|
committer | Narr the Reg <juangerman-13@hotmail.com> | 2024-01-05 18:41:15 +0100 |
commit | ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613 (patch) | |
tree | 3b95cbb74be05f0ce7a007353f1f9f95e1ed3901 /src/core/hle/service/hid/hidbus/hidbus_base.cpp | |
parent | Merge pull request #12437 from ameerj/gl-amd-fixes (diff) | |
download | yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.tar yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.tar.gz yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.tar.bz2 yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.tar.lz yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.tar.xz yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.tar.zst yuzu-ee847f8ff0b1b0aec39c1b78c010bc0c08a0a613.zip |
Diffstat (limited to 'src/core/hle/service/hid/hidbus/hidbus_base.cpp')
-rw-r--r-- | src/core/hle/service/hid/hidbus/hidbus_base.cpp | 73 |
1 files changed, 0 insertions, 73 deletions
diff --git a/src/core/hle/service/hid/hidbus/hidbus_base.cpp b/src/core/hle/service/hid/hidbus/hidbus_base.cpp deleted file mode 100644 index 8c44f93e8..000000000 --- a/src/core/hle/service/hid/hidbus/hidbus_base.cpp +++ /dev/null @@ -1,73 +0,0 @@ -// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project -// SPDX-License-Identifier: GPL-2.0-or-later - -#include "core/hid/hid_core.h" -#include "core/hle/kernel/k_event.h" -#include "core/hle/kernel/k_readable_event.h" -#include "core/hle/service/hid/hidbus/hidbus_base.h" -#include "core/hle/service/kernel_helpers.h" - -namespace Service::HID { - -HidbusBase::HidbusBase(Core::System& system_, KernelHelpers::ServiceContext& service_context_) - : system(system_), service_context(service_context_) { - send_command_async_event = service_context.CreateEvent("hidbus:SendCommandAsyncEvent"); -} - -HidbusBase::~HidbusBase() { - service_context.CloseEvent(send_command_async_event); -}; - -void HidbusBase::ActivateDevice() { - if (is_activated) { - return; - } - is_activated = true; - OnInit(); -} - -void HidbusBase::DeactivateDevice() { - if (is_activated) { - OnRelease(); - } - is_activated = false; -} - -bool HidbusBase::IsDeviceActivated() const { - return is_activated; -} - -void HidbusBase::Enable(bool enable) { - device_enabled = enable; -} - -bool HidbusBase::IsEnabled() const { - return device_enabled; -} - -bool HidbusBase::IsPollingMode() const { - return polling_mode_enabled; -} - -JoyPollingMode HidbusBase::GetPollingMode() const { - return polling_mode; -} - -void HidbusBase::SetPollingMode(JoyPollingMode mode) { - polling_mode = mode; - polling_mode_enabled = true; -} - -void HidbusBase::DisablePollingMode() { - polling_mode_enabled = false; -} - -void HidbusBase::SetTransferMemoryAddress(Common::ProcessAddress t_mem) { - transfer_memory = t_mem; -} - -Kernel::KReadableEvent& HidbusBase::GetSendCommandAsycEvent() const { - return send_command_async_event->GetReadableEvent(); -} - -} // namespace Service::HID |