File tree Expand file tree Collapse file tree 2 files changed +13
-3
lines changed
Expand file tree Collapse file tree 2 files changed +13
-3
lines changed Original file line number Diff line number Diff line change @@ -85,7 +85,6 @@ void GUI::Run() {
8585 MINIMUM_WINDOW_SIZE.x * dpiScaling,
8686 MINIMUM_WINDOW_SIZE.y * dpiScaling,
8787 });
88- ImGui::GetIO ().IniFilename = " test" ;
8988 platform.SetupFonts (&ImGui::GetIO ());
9089
9190 sf::Clock deltaClock {};
Original file line number Diff line number Diff line change 11// Copyright 2023 Fred Emmott <[email protected] >22// SPDX-License-Identifier: ISC
33
4- #include < Windows.h>
5-
64#include < Unknwn.h>
5+ #include < Windows.h>
76
87#include < winrt/base.h>
98
@@ -36,6 +35,18 @@ class PlatformGUI_Windows final : public PlatformGUI {
3635 }
3736
3837 void SetWindow (sf::WindowHandle handle) override {
38+ {
39+ static std::once_flag sOnce ;
40+
41+ std::call_once (sOnce , []() {
42+ static std::string sIniPath ;
43+ sIniPath = (GetKnownFolderPath<FOLDERID_LocalAppData>()
44+ / " OpenXR API Layers GUI" / " imgui.ini" )
45+ .string ();
46+ ImGui::GetIO ().IniFilename = sIniPath .c_str ();
47+ });
48+ }
49+
3950 {
4051 ShowWindow (handle, SW_HIDE);
4152 BOOL darkMode = true ;
You can’t perform that action at this time.
0 commit comments