diff options
author | bunnei <bunneidev@gmail.com> | 2021-04-04 09:56:09 +0200 |
---|---|---|
committer | bunnei <bunneidev@gmail.com> | 2021-05-06 01:40:50 +0200 |
commit | addc0bf0379e075786048921bede6e089552a6db (patch) | |
tree | 7fa8819b52db29e1b354410441dd8f2438e2ed4a /src/core/hle/service/hid/controllers/npad.cpp | |
parent | hle: kernel: Migrate KSharedMemory to KAutoObject. (diff) | |
download | yuzu-addc0bf0379e075786048921bede6e089552a6db.tar yuzu-addc0bf0379e075786048921bede6e089552a6db.tar.gz yuzu-addc0bf0379e075786048921bede6e089552a6db.tar.bz2 yuzu-addc0bf0379e075786048921bede6e089552a6db.tar.lz yuzu-addc0bf0379e075786048921bede6e089552a6db.tar.xz yuzu-addc0bf0379e075786048921bede6e089552a6db.tar.zst yuzu-addc0bf0379e075786048921bede6e089552a6db.zip |
Diffstat (limited to 'src/core/hle/service/hid/controllers/npad.cpp')
-rw-r--r-- | src/core/hle/service/hid/controllers/npad.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/core/hle/service/hid/controllers/npad.cpp b/src/core/hle/service/hid/controllers/npad.cpp index 9d07ca09c..7d9debc09 100644 --- a/src/core/hle/service/hid/controllers/npad.cpp +++ b/src/core/hle/service/hid/controllers/npad.cpp @@ -253,9 +253,8 @@ void Controller_NPad::InitNewlyAddedController(std::size_t controller_idx) { void Controller_NPad::OnInit() { auto& kernel = system.Kernel(); for (std::size_t i = 0; i < styleset_changed_events.size(); ++i) { - styleset_changed_events[i] = - Kernel::KEvent::Create(kernel, fmt::format("npad:NpadStyleSetChanged_{}", i)); - styleset_changed_events[i]->Initialize(); + styleset_changed_events[i] = std::make_unique<Kernel::KEvent>(kernel); + styleset_changed_events[i]->Initialize(fmt::format("npad:NpadStyleSetChanged_{}", i)); } if (!IsControllerActivated()) { |