make it a bit better

This commit is contained in:
Arisotura 2020-05-28 16:04:22 +02:00
parent f7e53c6f71
commit d25dc40e70
1 changed files with 4 additions and 1 deletions

View File

@ -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);