From 5bf237ce5795ac57a5c30400e90fab7be54220f9 Mon Sep 17 00:00:00 2001 From: Jade Macho Date: Sun, 29 Jun 2025 23:50:57 +0200 Subject: [PATCH] debug: Debug builds now launch in debug mode and with settings open --- CustomResolution2782/DebugConfiguration.cs | 7 ++++++- CustomResolution2782/PluginUI.cs | 4 ++++ 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/CustomResolution2782/DebugConfiguration.cs b/CustomResolution2782/DebugConfiguration.cs index b353d92..729c51e 100644 --- a/CustomResolution2782/DebugConfiguration.cs +++ b/CustomResolution2782/DebugConfiguration.cs @@ -6,7 +6,12 @@ namespace CustomResolution; /// public class DebugConfiguration { - public bool IsDebug { get; set; } = false; + public bool IsDebug { get; set; } = +#if DEBUG + true; +#else + false; +#endif public SetWindowSizeMode SetWindowSizeMode { get; set; } = SetWindowSizeMode.InterceptSystemConfig; diff --git a/CustomResolution2782/PluginUI.cs b/CustomResolution2782/PluginUI.cs index d6454f1..706add7 100644 --- a/CustomResolution2782/PluginUI.cs +++ b/CustomResolution2782/PluginUI.cs @@ -15,6 +15,10 @@ public sealed class PluginUI : IDisposable Service.PluginInterface.UiBuilder.OpenConfigUi += ShowConfigWindow; WindowSystem.AddWindow(_configWindow = new ConfigWindow()); + +#if DEBUG + SettingsVisible = true; +#endif } public WindowSystem WindowSystem { get; } = new("CustomResolution");