Skip to content

Commit

Permalink
Set Preference dialog modality
Browse files Browse the repository at this point in the history
  • Loading branch information
nikkiwritescode committed Jun 26, 2024
1 parent dda645b commit c9b9348
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 3 deletions.
1 change: 1 addition & 0 deletions mainwindow.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,7 @@ MainWindow::MainWindow(QWidget *parent)
});
connect(ui->actionPreferences, &QAction::triggered, this, [&]() {
PreferencesDialog dialog;
dialog.setWindowModality(Qt::ApplicationModal);
dialog.exec();
});
updateModListWidget();
Expand Down
4 changes: 2 additions & 2 deletions preferencesdialog.ui
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@
<string>Preferences</string>
</property>
<property name="sizeGripEnabled">
<bool>true</bool>
<bool>false</bool>
</property>
<property name="modal">
<bool>true</bool>
Expand Down Expand Up @@ -606,7 +606,7 @@
</connection>
</connections>
<buttongroups>
<buttongroup name="cacheModeBtnGroup"/>
<buttongroup name="csmmModeBtnGroup"/>
<buttongroup name="cacheModeBtnGroup"/>
</buttongroups>
</ui>
1 change: 1 addition & 0 deletions quicksetupdialog.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ void QuickSetupDialog::onResultClick(QAbstractButton *button)

if (button == toPreferences){
PreferencesDialog dialog;
dialog.setWindowModality(Qt::ApplicationModal);
dialog.exec();
return;
}
Expand Down
2 changes: 1 addition & 1 deletion quicksetupdialog.ui
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<string>Quick Setup</string>
</property>
<property name="modal">
<bool>true</bool>
<bool>false</bool>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<item>
Expand Down

0 comments on commit c9b9348

Please sign in to comment.