Просмотр исходного кода

UI: Don't cap auto-config wizard FPS whole number precision at 2

Capping the precision for whole numbers results in scientific notation
being used for any number that's larger than what can be displayed with
the given precision. In case of 2, that would be anything larger than
99, resulting in 120 for example to be shown as 1.2e+02.
Let's not cap the precision for whole numbers ourselves and just use the
default value (which at the time of writing would be 6).
gxalpha 2 лет назад
Родитель
Сommit
d2ef4d21b3
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      UI/window-basic-auto-config.cpp

+ 1 - 1
UI/window-basic-auto-config.cpp

@@ -136,7 +136,7 @@ AutoConfigVideoPage::AutoConfigVideoPage(QWidget *parent)
 		(long double)ovi.fps_num / (long double)ovi.fps_den;
 
 	QString fpsStr = (ovi.fps_den > 1) ? QString::number(fpsVal, 'f', 2)
-					   : QString::number(fpsVal, 'g', 2);
+					   : QString::number(fpsVal, 'g');
 
 	ui->fps->addItem(QTStr(FPS_PREFER_HIGH_FPS),
 			 (int)AutoConfig::FPSType::PreferHighFPS);