diff options
author | Arisotura <thetotalworm@gmail.com> | 2020-05-28 16:04:22 +0200 |
---|---|---|
committer | Arisotura <thetotalworm@gmail.com> | 2020-05-28 16:04:22 +0200 |
commit | d25dc40e70e9a1c25966db8e16a5efd5284fd336 (patch) | |
tree | e3f42c226fbb385d707ccb011f64bdffcbe7bef0 /src | |
parent | f7e53c6f71c3bf6f082d1e5857f474f79f992602 (diff) |
make it a bit better
Diffstat (limited to 'src')
-rw-r--r-- | src/frontend/qt_sdl/VideoSettingsDialog.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/frontend/qt_sdl/VideoSettingsDialog.cpp b/src/frontend/qt_sdl/VideoSettingsDialog.cpp index 09f1ab4..9645a3d 100644 --- a/src/frontend/qt_sdl/VideoSettingsDialog.cpp +++ b/src/frontend/qt_sdl/VideoSettingsDialog.cpp @@ -59,7 +59,7 @@ VideoSettingsDialog::VideoSettingsDialog(QWidget* parent) : QDialog(parent), ui( for (int i = 1; i <= 16; i++) ui->cbxGLResolution->addItem(QString("%1x native (%2x%3)").arg(i).arg(256*i).arg(192*i)); ui->cbxGLResolution->setCurrentIndex(Config::GL_ScaleFactor-1); - +printf("GL scale = %d\n", Config::GL_ScaleFactor); if (Config::_3DRenderer == 0) { ui->cbGLDisplay->setEnabled(true); @@ -145,6 +145,9 @@ void VideoSettingsDialog::on_cbSoftwareThreaded_stateChanged(int state) void VideoSettingsDialog::on_cbxGLResolution_currentIndexChanged(int idx) { + // prevent a spurious change + if (ui->cbxGLResolution->count() < 16) return; + Config::GL_ScaleFactor = idx+1; emit updateVideoSettings(false); |