Always show actual vsync setting in the interface instead of desired setting.
parent
d71934c8e5
commit
195159406d
|
@ -944,17 +944,16 @@ bool runVideoOptionsMenu(void)
|
||||||
case FRONTEND_VSYNC:
|
case FRONTEND_VSYNC:
|
||||||
case FRONTEND_VSYNC_R:
|
case FRONTEND_VSYNC_R:
|
||||||
{
|
{
|
||||||
|
WzMainWindow::instance()->setSwapInterval(!war_GetVsync());
|
||||||
|
war_SetVsync(WzMainWindow::instance()->swapInterval() > 0);
|
||||||
if (war_GetVsync())
|
if (war_GetVsync())
|
||||||
{
|
{
|
||||||
war_SetVsync(false);
|
|
||||||
widgSetString(psWScreen, FRONTEND_VSYNC_R, _("Off"));
|
widgSetString(psWScreen, FRONTEND_VSYNC_R, _("Off"));
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
war_SetVsync(true);
|
|
||||||
widgSetString(psWScreen, FRONTEND_VSYNC_R, _("On"));
|
widgSetString(psWScreen, FRONTEND_VSYNC_R, _("On"));
|
||||||
}
|
}
|
||||||
WzMainWindow::instance()->setSwapInterval(war_GetVsync());
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -1299,6 +1299,7 @@ int main(int argc, char *argv[])
|
||||||
}
|
}
|
||||||
|
|
||||||
mainwindow.setSwapInterval(war_GetVsync());
|
mainwindow.setSwapInterval(war_GetVsync());
|
||||||
|
war_SetVsync(mainwindow.swapInterval() > 0);
|
||||||
|
|
||||||
mainwindow.setReadyToPaint();
|
mainwindow.setReadyToPaint();
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue