clang-format in src/qt

This commit is contained in:
Jasmine Iwanek
2025-10-03 22:42:29 -04:00
parent 10151c738d
commit ca424aed32
104 changed files with 3358 additions and 3294 deletions

View File

@@ -187,8 +187,7 @@ Settings::Settings(QWidget *parent)
&SettingsOtherRemovable::reloadBusChannels_MO);
connect(ui->listView->selectionModel(), &QItemSelectionModel::currentChanged, this,
[this](const QModelIndex &current, const QModelIndex &previous) {
ui->stackedWidget->setCurrentIndex(current.row()); });
[this](const QModelIndex &current, const QModelIndex &previous) { ui->stackedWidget->setCurrentIndex(current.row()); });
ui->listView->setCurrentIndex(model->index(0, 0));
@@ -224,14 +223,12 @@ Settings::accept()
{
if (confirm_save && !settings_only) {
QMessageBox questionbox(QMessageBox::Icon::Question, "86Box",
QStringLiteral("%1\n\n%2").arg(tr("Do you want to save the settings?"),
tr("This will hard reset the emulated machine.")),
QStringLiteral("%1\n\n%2").arg(tr("Do you want to save the settings?"), tr("This will hard reset the emulated machine.")),
QMessageBox::Save | QMessageBox::Cancel, this);
QCheckBox *chkbox = new QCheckBox(tr("Don't show this message again"));
questionbox.setCheckBox(chkbox);
chkbox->setChecked(!confirm_save);
QObject::connect(chkbox, &QCheckBox::stateChanged, [](int state) {
confirm_save = (state == Qt::CheckState::Unchecked); });
QObject::connect(chkbox, &QCheckBox::stateChanged, [](int state) { confirm_save = (state == Qt::CheckState::Unchecked); });
questionbox.exec();
if (questionbox.result() == QMessageBox::Cancel) {
confirm_save = true;