diff --git a/rpcs3/rpcs3qt/emu_settings.cpp b/rpcs3/rpcs3qt/emu_settings.cpp index b08e094b01..9daaeb2740 100644 --- a/rpcs3/rpcs3qt/emu_settings.cpp +++ b/rpcs3/rpcs3qt/emu_settings.cpp @@ -441,9 +441,9 @@ void emu_settings::EnhanceCheckBox(QCheckBox* checkbox, emu_settings_type type) m_broken_types.insert(type); } - connect(checkbox, &QCheckBox::stateChanged, this, [type, this](int val) + connect(checkbox, &QCheckBox::checkStateChanged, this, [type, this](Qt::CheckState val) { - const std::string str = val != 0 ? "true" : "false"; + const std::string str = val != Qt::Unchecked ? "true" : "false"; SetSetting(type, str); }); diff --git a/rpcs3/rpcs3qt/pad_motion_settings_dialog.cpp b/rpcs3/rpcs3qt/pad_motion_settings_dialog.cpp index dd7784a727..0ebdbdb7c9 100644 --- a/rpcs3/rpcs3qt/pad_motion_settings_dialog.cpp +++ b/rpcs3/rpcs3qt/pad_motion_settings_dialog.cpp @@ -99,7 +99,7 @@ pad_motion_settings_dialog::pad_motion_settings_dialog(QDialog* parent, std::sha m_shifts[i]->setRange(config->shift.min, config->shift.max); m_shifts[i]->setValue(config->shift.get()); - connect(m_mirrors[i], &QCheckBox::stateChanged, this, [this, i](int state) + connect(m_mirrors[i], &QCheckBox::checkStateChanged, this, [this, i](Qt::CheckState state) { std::lock_guard lock(m_config_mutex); m_config_entries[i]->mirrored.set(state != Qt::Unchecked); diff --git a/rpcs3/rpcs3qt/patch_manager_dialog.cpp b/rpcs3/rpcs3qt/patch_manager_dialog.cpp index 5fa2b5fef3..1b250f789b 100644 --- a/rpcs3/rpcs3qt/patch_manager_dialog.cpp +++ b/rpcs3/rpcs3qt/patch_manager_dialog.cpp @@ -93,7 +93,7 @@ patch_manager_dialog::patch_manager_dialog(std::shared_ptr gui_set connect(ui->patch_tree, &QTreeWidget::currentItemChanged, this, &patch_manager_dialog::handle_item_selected); connect(ui->patch_tree, &QTreeWidget::itemChanged, this, &patch_manager_dialog::handle_item_changed); connect(ui->patch_tree, &QTreeWidget::customContextMenuRequested, this, &patch_manager_dialog::handle_custom_context_menu_requested); - connect(ui->cb_owned_games_only, &QCheckBox::stateChanged, this, &patch_manager_dialog::handle_show_owned_games_only); + connect(ui->cb_owned_games_only, &QCheckBox::checkStateChanged, this, &patch_manager_dialog::handle_show_owned_games_only); connect(ui->configurable_selector, QOverload::of(&QComboBox::currentIndexChanged), this, [this](int index) { if (index >= 0) @@ -1087,7 +1087,7 @@ void patch_manager_dialog::dropEvent(QDropEvent* event) } } -void patch_manager_dialog::handle_show_owned_games_only(int state) +void patch_manager_dialog::handle_show_owned_games_only(Qt::CheckState state) { m_show_owned_games_only = state == Qt::CheckState::Checked; m_gui_settings->SetValue(gui::pm_show_owned, m_show_owned_games_only); diff --git a/rpcs3/rpcs3qt/patch_manager_dialog.h b/rpcs3/rpcs3qt/patch_manager_dialog.h index d2d57e12c9..fd4ed40b81 100644 --- a/rpcs3/rpcs3qt/patch_manager_dialog.h +++ b/rpcs3/rpcs3qt/patch_manager_dialog.h @@ -50,7 +50,7 @@ private Q_SLOTS: void handle_item_changed(QTreeWidgetItem* item, int column); void handle_config_value_changed(double value); void handle_custom_context_menu_requested(const QPoint& pos); - void handle_show_owned_games_only(int state); + void handle_show_owned_games_only(Qt::CheckState state); private: void refresh(bool restore_layout = false); diff --git a/rpcs3/rpcs3qt/settings_dialog.cpp b/rpcs3/rpcs3qt/settings_dialog.cpp index 36fc6dc932..00aebbabf9 100644 --- a/rpcs3/rpcs3qt/settings_dialog.cpp +++ b/rpcs3/rpcs3qt/settings_dialog.cpp @@ -1433,7 +1433,7 @@ settings_dialog::settings_dialog(std::shared_ptr gui_settings, std if (game) ui->gb_DiskCacheClearing->setDisabled(true); else - connect(ui->enableCacheClearing, &QCheckBox::stateChanged, ui->maximumCacheSize, &QSlider::setEnabled); + connect(ui->enableCacheClearing, &QCheckBox::checkStateChanged, ui->maximumCacheSize, &QSlider::setEnabled); // Date Time Edit Box m_emu_settings->EnhanceDateTimeEdit(ui->console_time_edit, emu_settings_type::ConsoleTimeOffset, tr("dd MMM yyyy HH:mm"), true, true, 15000); @@ -1580,7 +1580,7 @@ settings_dialog::settings_dialog(std::shared_ptr gui_settings, std ui->mfcDelayCommand->setChecked(m_emu_settings->GetSetting(emu_settings_type::MFCCommandsShuffling) == "1"); SubscribeTooltip(ui->mfcDelayCommand, tooltips.settings.mfc_delay_command); - connect(ui->mfcDelayCommand, &QCheckBox::stateChanged, [&](int val) + connect(ui->mfcDelayCommand, &QCheckBox::checkStateChanged, [&](Qt::CheckState val) { const std::string str = val != Qt::Unchecked ? "1" : "0"; m_emu_settings->SetSetting(emu_settings_type::MFCCommandsShuffling, str); diff --git a/rpcs3/rpcs3qt/trophy_manager_dialog.cpp b/rpcs3/rpcs3qt/trophy_manager_dialog.cpp index c43a38f591..b918330d9e 100644 --- a/rpcs3/rpcs3qt/trophy_manager_dialog.cpp +++ b/rpcs3/rpcs3qt/trophy_manager_dialog.cpp @@ -33,6 +33,7 @@ #include #include #include +#include LOG_CHANNEL(gui_log, "GUI"); @@ -1342,7 +1343,7 @@ QDateTime trophy_manager_dialog::TickToDateTime(u64 tick) const QDateTime datetime( QDate(rtc_date.year, rtc_date.month, rtc_date.day), QTime(rtc_date.hour, rtc_date.minute, rtc_date.second, rtc_date.microsecond / 1000), - Qt::TimeSpec::UTC); + QTimeZone::UTC); return datetime.toLocalTime(); }