aboutsummaryrefslogtreecommitdiff
path: root/src/core/hle/service/nfp/nfp.cpp
diff options
context:
space:
mode:
authorbunnei <bunneidev@gmail.com>2021-04-10 02:34:26 -0700
committerbunnei <bunneidev@gmail.com>2021-05-05 16:40:51 -0700
commit2e8d6fe9a0c07538397682e1cb25992bfd15676d (patch)
tree444ee462a197818e0114150a03c0a5898cadaa19 /src/core/hle/service/nfp/nfp.cpp
parenteba3bb9d219283ffc2a7610d925aa157a81b6e4a (diff)
hle: kernel: Migrate KReadableEvent and KWritableEvent to KAutoObject.
Diffstat (limited to 'src/core/hle/service/nfp/nfp.cpp')
-rw-r--r--src/core/hle/service/nfp/nfp.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/core/hle/service/nfp/nfp.cpp b/src/core/hle/service/nfp/nfp.cpp
index d1cf01390..d25b20ab5 100644
--- a/src/core/hle/service/nfp/nfp.cpp
+++ b/src/core/hle/service/nfp/nfp.cpp
@@ -175,7 +175,7 @@ private:
switch (device_state) {
case DeviceState::TagFound:
case DeviceState::TagNearby:
- deactivate_event.GetWritableEvent()->Signal();
+ deactivate_event.GetWritableEvent().Signal();
device_state = DeviceState::Initialized;
break;
case DeviceState::SearchingForTag:
@@ -318,7 +318,7 @@ private:
const u32 npad_id{0}; // Player 1 controller
State state{State::NonInitialized};
DeviceState device_state{DeviceState::Initialized};
- const Module::Interface& nfp_interface;
+ Module::Interface& nfp_interface;
Kernel::KEvent deactivate_event;
Kernel::KEvent availability_change_event;
};
@@ -338,12 +338,12 @@ bool Module::Interface::LoadAmiibo(const std::vector<u8>& buffer) {
}
std::memcpy(&amiibo, buffer.data(), sizeof(amiibo));
- nfc_tag_load.GetWritableEvent()->Signal();
+ nfc_tag_load.GetWritableEvent().Signal();
return true;
}
-Kernel::KReadableEvent* Module::Interface::GetNFCEvent() const {
- return nfc_tag_load.GetReadableEvent().get();
+Kernel::KReadableEvent& Module::Interface::GetNFCEvent() {
+ return nfc_tag_load.GetReadableEvent();
}
const Module::Interface::AmiiboFile& Module::Interface::GetAmiiboBuffer() const {