Add vsync toggle & honor fullscreen setting

This commit is contained in:
Luke Street
2026-04-06 23:07:48 -06:00
parent 1a0f490dfd
commit 462001d398
5 changed files with 15 additions and 1 deletions
+9
View File
@@ -14,6 +14,8 @@
#include "m_Do/m_Do_controller_pad.h"
#include "m_Do/m_Do_graphic.h"
#include <aurora/gfx.h>
namespace dusk {
void ImGuiMenuGame::ToggleFullscreen() {
getSettings().video.enableFullscreen.setValue(!getSettings().video.enableFullscreen);
@@ -36,6 +38,13 @@ namespace dusk {
ToggleFullscreen();
}
bool vsync = getSettings().video.enableVsync;
if (ImGui::Checkbox("Enable Vsync", &vsync)) {
getSettings().video.enableVsync.setValue(vsync);
aurora_enable_vsync(vsync);
config::Save();
}
if (ImGui::MenuItem("Default Window Size")) {
getSettings().video.enableFullscreen.setValue(false);
VISetWindowFullscreen(false);