[qt] use checkStateChanged over stateChanged (former is deprecated)
Some checks failed
eden-license / license-header (pull_request) Failing after 27s

Signed-off-by: lizzie <lizzie@eden-emu.dev>
This commit is contained in:
lizzie 2025-08-07 05:16:40 +01:00 committed by crueter
parent 57fbdd516e
commit abd12243ec
7 changed files with 15 additions and 15 deletions

View file

@ -184,7 +184,7 @@ QtControllerSelectorDialog::QtControllerSelectorDialog(
CheckIfParametersMet();
});
connect(connected_controller_checkboxes[i], &QCheckBox::stateChanged, [this, i](int state) {
connect(connected_controller_checkboxes[i], &QCheckBox::checkStateChanged, [this, i](int state) {
player_groupboxes[i]->setChecked(state == Qt::Checked);
UpdateControllerIcon(i);
UpdateControllerState(i);

View file

@ -29,9 +29,9 @@ ConfigureFilesystem::ConfigureFilesystem(QWidget* parent)
connect(ui->reset_game_list_cache, &QPushButton::pressed, this,
&ConfigureFilesystem::ResetMetadata);
connect(ui->gamecard_inserted, &QCheckBox::stateChanged, this,
connect(ui->gamecard_inserted, &QCheckBox::checkStateChanged, this,
&ConfigureFilesystem::UpdateEnabledControls);
connect(ui->gamecard_current_game, &QCheckBox::stateChanged, this,
connect(ui->gamecard_current_game, &QCheckBox::checkStateChanged, this,
&ConfigureFilesystem::UpdateEnabledControls);
}

View file

@ -124,7 +124,7 @@ void ConfigureInput::Initialize(InputCommon::InputSubsystem* input_subsystem,
&ConfigureInput::UpdateAllInputDevices);
connect(player_controllers[i], &ConfigureInputPlayer::RefreshInputProfiles, this,
&ConfigureInput::UpdateAllInputProfiles, Qt::QueuedConnection);
connect(connected_controller_checkboxes[i], &QCheckBox::stateChanged, [this, i](int state) {
connect(connected_controller_checkboxes[i], &QCheckBox::checkStateChanged, [this, i](int state) {
// Keep activated controllers synced with the "Connected Controllers" checkboxes
player_controllers[i]->ConnectPlayer(state == Qt::Checked);
});

View file

@ -74,13 +74,13 @@ ConfigureInputAdvanced::ConfigureInputAdvanced(Core::HID::HIDCore& hid_core_, QW
}
}
connect(ui->mouse_enabled, &QCheckBox::stateChanged, this,
connect(ui->mouse_enabled, &QCheckBox::checkStateChanged, this,
&ConfigureInputAdvanced::UpdateUIEnabled);
connect(ui->debug_enabled, &QCheckBox::stateChanged, this,
connect(ui->debug_enabled, &QCheckBox::checkStateChanged, this,
&ConfigureInputAdvanced::UpdateUIEnabled);
connect(ui->touchscreen_enabled, &QCheckBox::stateChanged, this,
connect(ui->touchscreen_enabled, &QCheckBox::checkStateChanged, this,
&ConfigureInputAdvanced::UpdateUIEnabled);
connect(ui->enable_ring_controller, &QCheckBox::stateChanged, this,
connect(ui->enable_ring_controller, &QCheckBox::checkStateChanged, this,
&ConfigureInputAdvanced::UpdateUIEnabled);
connect(ui->debug_configure, &QPushButton::clicked, this,

View file

@ -83,7 +83,7 @@ ConfigureSystem::ConfigureSystem(Core::System& system_,
connect(combo_language, qOverload<int>(&QComboBox::currentIndexChanged), this, locale_check);
connect(combo_region, qOverload<int>(&QComboBox::currentIndexChanged), this, locale_check);
connect(checkbox_rtc, qOverload<int>(&QCheckBox::stateChanged), this, update_rtc_date);
connect(checkbox_rtc, &QCheckBox::checkStateChanged, this, update_rtc_date);
connect(date_rtc_offset, qOverload<int>(&QSpinBox::valueChanged), this, update_rtc_date);
connect(date_rtc, &QDateTimeEdit::dateTimeChanged, this, update_date_offset);

View file

@ -119,11 +119,11 @@ ConfigureUi::ConfigureUi(Core::System& system_, QWidget* parent)
SetConfiguration();
// Force game list reload if any of the relevant settings are changed.
connect(ui->show_add_ons, &QCheckBox::stateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_compat, &QCheckBox::stateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_size, &QCheckBox::stateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_types, &QCheckBox::stateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_play_time, &QCheckBox::stateChanged, this,
connect(ui->show_add_ons, &QCheckBox::checkStateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_compat, &QCheckBox::checkStateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_size, &QCheckBox::checkStateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_types, &QCheckBox::checkStateChanged, this, &ConfigureUi::RequestGameListUpdate);
connect(ui->show_play_time, &QCheckBox::checkStateChanged, this,
&ConfigureUi::RequestGameListUpdate);
connect(ui->game_icon_size_combobox, QOverload<int>::of(&QComboBox::currentIndexChanged), this,
&ConfigureUi::RequestGameListUpdate);

View file

@ -697,7 +697,7 @@ void Widget::SetupComponent(const QString& label, std::function<void()>& load_fu
restore_func();
}
};
connect(checkbox, &QCheckBox::stateChanged, reset);
connect(checkbox, &QCheckBox::checkStateChanged, reset);
reset(checkbox->checkState());
}
}