mirror of
https://github.com/yuzu-emu/yuzu-android.git
synced 2025-06-28 06:57:57 -05:00
yuzu: config: Remove player 8 and 9 from config file
This commit is contained in:
@ -212,16 +212,11 @@ void Config::ReadPlayerValue(std::size_t player_index) {
|
||||
}
|
||||
|
||||
if (player_prefix.isEmpty() && Settings::IsConfiguringGlobal()) {
|
||||
const auto controller = static_cast<Settings::ControllerType>(
|
||||
player.controller_type = static_cast<Settings::ControllerType>(
|
||||
qt_config
|
||||
->value(QStringLiteral("%1type").arg(player_prefix),
|
||||
static_cast<u8>(Settings::ControllerType::ProController))
|
||||
.toUInt());
|
||||
|
||||
if (controller == Settings::ControllerType::LeftJoycon ||
|
||||
controller == Settings::ControllerType::RightJoycon) {
|
||||
player.controller_type = controller;
|
||||
}
|
||||
} else {
|
||||
player.connected =
|
||||
ReadSetting(QStringLiteral("%1connected").arg(player_prefix), player_index == 0)
|
||||
|
@ -57,7 +57,7 @@ void ConfigureInputPerGame::ApplyConfiguration() {
|
||||
}
|
||||
|
||||
void ConfigureInputPerGame::LoadConfiguration() {
|
||||
static constexpr size_t HANDHELD_INDEX = 8;
|
||||
static constexpr size_t HANDHELD_INDEX = 0;
|
||||
|
||||
auto& hid_core = system.HIDCore();
|
||||
for (size_t player_index = 0; player_index < profile_comboboxes.size(); ++player_index) {
|
||||
@ -69,9 +69,6 @@ void ConfigureInputPerGame::LoadConfiguration() {
|
||||
const auto selection_index = player_combobox->currentIndex();
|
||||
if (selection_index == 0) {
|
||||
Settings::values.players.GetValue()[player_index].profile_name = "";
|
||||
if (player_index == 0) {
|
||||
Settings::values.players.GetValue()[HANDHELD_INDEX] = {};
|
||||
}
|
||||
Settings::values.players.SetGlobal(true);
|
||||
emulated_controller->ReloadFromSettings();
|
||||
continue;
|
||||
|
@ -1589,7 +1589,6 @@ void ConfigureInputPlayer::LoadProfile() {
|
||||
}
|
||||
|
||||
void ConfigureInputPlayer::SaveProfile() {
|
||||
static constexpr size_t HANDHELD_INDEX = 8;
|
||||
const QString profile_name = ui->comboProfiles->itemText(ui->comboProfiles->currentIndex());
|
||||
|
||||
if (profile_name.isEmpty()) {
|
||||
@ -1598,12 +1597,7 @@ void ConfigureInputPlayer::SaveProfile() {
|
||||
|
||||
ApplyConfiguration();
|
||||
|
||||
// When we're in handheld mode, only the handheld emulated controller bindings are updated
|
||||
const bool is_handheld = player_index == 0 && emulated_controller->GetNpadIdType() ==
|
||||
Core::HID::NpadIdType::Handheld;
|
||||
const auto profile_player_index = is_handheld ? HANDHELD_INDEX : player_index;
|
||||
|
||||
if (!profiles->SaveProfile(profile_name.toStdString(), profile_player_index)) {
|
||||
if (!profiles->SaveProfile(profile_name.toStdString(), player_index)) {
|
||||
QMessageBox::critical(this, tr("Save Input Profile"),
|
||||
tr("Failed to save the input profile \"%1\"").arg(profile_name));
|
||||
UpdateInputProfiles();
|
||||
|
Reference in New Issue
Block a user