Keep emulator paused while settings is open

Reduces crashes
This commit is contained in:
Cacodemon345
2021-12-01 14:50:49 +06:00
parent dcf492b299
commit ac52b32adb

View File

@@ -116,7 +116,11 @@ void MainWindow::on_actionExit_triggered() {
}
void MainWindow::on_actionSettings_triggered() {
Settings settings;
int currentPause = dopause;
plat_pause(1);
Settings settings(this);
settings.setModal(true);
settings.setWindowModality(Qt::WindowModal);
settings.exec();
switch (settings.result()) {
@@ -135,6 +139,7 @@ void MainWindow::on_actionSettings_triggered() {
case QDialog::Rejected:
break;
}
plat_pause(currentPause);
}
std::array<uint32_t, 256> x11_to_xt_base