EVEN MORE FIXES

This commit is contained in:
lizzie 2026-03-18 00:34:01 +00:00 committed by crueter
parent 4519450d48
commit a8b1ad7ea8
No known key found for this signature in database
GPG key ID: 425ACD2D4830EBC6
2 changed files with 47 additions and 82 deletions

View file

@ -1,3 +1,6 @@
// SPDX-FileCopyrightText: Copyright 2026 Eden Emulator Project
// SPDX-License-Identifier: GPL-3.0-or-later
// SPDX-FileCopyrightText: Copyright 2021 yuzu Emulator Project
// SPDX-License-Identifier: GPL-2.0-or-later
@ -55,11 +58,11 @@ void ControllerNavigation::ControllerUpdateEvent(Core::HID::ControllerTriggerTyp
void ControllerNavigation::ControllerUpdateButton() {
const auto controller_type = player1_controller->GetNpadStyleIndex();
const auto& player1_buttons = player1_controller->GetButtonsValues();
const auto& handheld_buttons = handheld_controller->GetButtonsValues();
const auto& player1_btns = player1_controller->GetButtonsValues();
const auto& handheld_btns = handheld_controller->GetButtonsValues();
for (std::size_t i = 0; i < player1_buttons.size(); ++i) {
const bool button = player1_buttons[i].value || handheld_buttons[i].value;
for (std::size_t i = 0; i < player1_btns.size(); ++i) {
const bool button = player1_btns[i].value || handheld_btns[i].value;
// Trigger only once
button_values[i].locked = button == button_values[i].value;
button_values[i].value = button;