Code refinement. Added UI menu to user settings

Added markers to menu for settings related to global settings
This commit is contained in:
Vova 2025-02-15 19:59:23 +10:00
parent af00ca6ed8
commit 24867ec9b6
8 changed files with 146 additions and 68 deletions

View File

@ -46,6 +46,8 @@
<MenuItem <MenuItem
Header="123 0000" Header="123 0000"
ToolTip.Tip="What this"/> ToolTip.Tip="What this"/>
<TextBlock
Classes="globalConfigMarker"/>
</StackPanel> </StackPanel>
</Border> </Border>
@ -337,6 +339,14 @@
<Setter Property="Margin" <Setter Property="Margin"
Value="0,5,0,0" /> Value="0,5,0,0" />
</Style> </Style>
<Style Selector="TextBlock.globalConfigMarker" >
<Setter Property="Foreground" Value="SeaGreen"/>
<Setter Property="Margin" Value="5,0,0,0"/>
<Setter Property="VerticalAlignment" Value="Center"/>
<Setter Property="Text" Value="(Global)"/>
</Style>
<Style Selector="StackPanel.globalConfigMarker">
</Style>
<Style Selector="ContextMenu"> <Style Selector="ContextMenu">
<Setter Property="BorderBrush" <Setter Property="BorderBrush"
Value="{DynamicResource MenuFlyoutPresenterBorderBrush}" /> Value="{DynamicResource MenuFlyoutPresenterBorderBrush}" />
@ -389,6 +399,9 @@
<Setter Property="Background" Value="{DynamicResource WarningBackgroundColor}" /> <Setter Property="Background" Value="{DynamicResource WarningBackgroundColor}" />
<Setter Property="Foreground" Value="White"/> <Setter Property="Foreground" Value="White"/>
</Style> </Style>
<Styles.Resources> <Styles.Resources>
<SolidColorBrush x:Key="ThemeAccentColorBrush" <SolidColorBrush x:Key="ThemeAccentColorBrush"
Color="{DynamicResource SystemAccentColor}" /> Color="{DynamicResource SystemAccentColor}" />

View File

@ -169,6 +169,11 @@ namespace Ryujinx.Ava
public static string GetDirGameUserConfig(string gameId, bool rememberGlobalDir = false, bool changeFolderForGame = false) public static string GetDirGameUserConfig(string gameId, bool rememberGlobalDir = false, bool changeFolderForGame = false)
{ {
if (string.IsNullOrEmpty(gameId))
{
return "";
}
string gameDir = Path.Combine(AppDataManager.GamesDirPath, gameId, ReleaseInformation.ConfigName); string gameDir = Path.Combine(AppDataManager.GamesDirPath, gameId, ReleaseInformation.ConfigName);
// Should load with the game if there is a custom setting for the game // Should load with the game if there is a custom setting for the game

View File

@ -81,6 +81,8 @@ namespace Ryujinx.Ava.UI.ViewModels
public string GamePath => _gamePath; public string GamePath => _gamePath;
public string GameTitle => _gameTitle; public string GameTitle => _gameTitle;
public string GameId => _gameId; public string GameId => _gameId;
public bool IsGameTitleNotNull => !string.IsNullOrEmpty(GameTitle);
public double PanelOpacity => IsGameTitleNotNull ? 0.5 : 1;
public int ResolutionScale public int ResolutionScale
{ {
@ -422,10 +424,8 @@ namespace Ryujinx.Ava.UI.ViewModels
{ {
Task.Run(LoadAvailableGpus); Task.Run(LoadAvailableGpus);
if (!noLoadGlobalConfig)// Default is false, but loading custom config avoids double call // if (!noLoadGlobalConfig)// Default is false, but loading custom config avoids double call
{
LoadCurrentConfiguration(); LoadCurrentConfiguration();
}
DirtyHacks = new SettingsHacksViewModel(this); DirtyHacks = new SettingsHacksViewModel(this);
} }
@ -536,35 +536,29 @@ namespace Ryujinx.Ava.UI.ViewModels
{ {
ConfigurationState config = ConfigurationState.Instance; ConfigurationState config = ConfigurationState.Instance;
// User Interface
EnableDiscordIntegration = config.EnableDiscordIntegration;
CheckUpdatesOnStart = config.CheckUpdatesOnStart;
ShowConfirmExit = config.ShowConfirmExit;
RememberWindowState = config.RememberWindowState;
ShowTitleBar = config.ShowTitleBar;
HideCursor = (int)config.HideCursor.Value;
UpdateCheckerType = (int)config.UpdateCheckerType.Value;
FocusLostActionType = (int)config.FocusLostActionType.Value;
//It is necessary that the data is used from the global configuration file GameDirectories.Clear();
if (string.IsNullOrEmpty(GameId)) GameDirectories.AddRange(config.UI.GameDirs.Value);
AutoloadDirectories.Clear();
AutoloadDirectories.AddRange(config.UI.AutoloadDirs.Value);
BaseStyleIndex = config.UI.BaseStyle.Value switch
{ {
// User Interface "Auto" => 0,
EnableDiscordIntegration = config.EnableDiscordIntegration; "Light" => 1,
CheckUpdatesOnStart = config.CheckUpdatesOnStart; "Dark" => 2,
ShowConfirmExit = config.ShowConfirmExit; _ => 0
RememberWindowState = config.RememberWindowState; };
ShowTitleBar = config.ShowTitleBar;
HideCursor = (int)config.HideCursor.Value;
UpdateCheckerType = (int)config.UpdateCheckerType.Value;
FocusLostActionType = (int)config.FocusLostActionType.Value;
GameDirectories.Clear();
GameDirectories.AddRange(config.UI.GameDirs.Value);
AutoloadDirectories.Clear();
AutoloadDirectories.AddRange(config.UI.AutoloadDirs.Value);
BaseStyleIndex = config.UI.BaseStyle.Value switch
{
"Auto" => 0,
"Light" => 1,
"Dark" => 2,
_ => 0
};
}
// Input // Input
EnableDockedMode = config.System.EnableDockedMode; EnableDockedMode = config.System.EnableDockedMode;
@ -585,6 +579,7 @@ namespace Ryujinx.Ava.UI.ViewModels
DateTime currentDateTime = currentHostDateTime.Add(systemDateTimeOffset); DateTime currentDateTime = currentHostDateTime.Add(systemDateTimeOffset);
CurrentDate = currentDateTime.Date; CurrentDate = currentDateTime.Date;
CurrentTime = currentDateTime.TimeOfDay; CurrentTime = currentDateTime.TimeOfDay;
MatchSystemTime = config.System.MatchSystemTime; MatchSystemTime = config.System.MatchSystemTime;
EnableCustomVSyncInterval = config.Graphics.EnableCustomVSyncInterval; EnableCustomVSyncInterval = config.Graphics.EnableCustomVSyncInterval;
@ -645,11 +640,10 @@ namespace Ryujinx.Ava.UI.ViewModels
LdnPassphrase = config.Multiplayer.LdnPassphrase; LdnPassphrase = config.Multiplayer.LdnPassphrase;
LdnServer = config.Multiplayer.LdnServer; LdnServer = config.Multiplayer.LdnServer;
} }
public void SaveSettings() public void SaveSettings()
{ {
ConfigurationState config = ConfigurationState.Instance; ConfigurationState config = ConfigurationState.Instance;
bool userConfigFile = string.IsNullOrEmpty(GameId);
// User Interface // User Interface
config.EnableDiscordIntegration.Value = EnableDiscordIntegration; config.EnableDiscordIntegration.Value = EnableDiscordIntegration;
@ -660,17 +654,16 @@ namespace Ryujinx.Ava.UI.ViewModels
config.HideCursor.Value = (HideCursorMode)HideCursor; config.HideCursor.Value = (HideCursorMode)HideCursor;
config.UpdateCheckerType.Value = (UpdaterType)UpdateCheckerType; config.UpdateCheckerType.Value = (UpdaterType)UpdateCheckerType;
config.FocusLostActionType.Value = (FocusLostType)FocusLostActionType; config.FocusLostActionType.Value = (FocusLostType)FocusLostActionType;
config.UI.GameDirs.Value = [..GameDirectories]; config.UI.GameDirs.Value = [.. GameDirectories];
config.UI.AutoloadDirs.Value = [..AutoloadDirectories]; config.UI.AutoloadDirs.Value = [.. AutoloadDirectories];
config.UI.BaseStyle.Value = BaseStyleIndex switch
config.UI.BaseStyle.Value = BaseStyleIndex switch {
{ 0 => "Auto",
0 => "Auto", 1 => "Light",
1 => "Light", 2 => "Dark",
2 => "Dark", _ => "Auto"
_ => "Auto" };
};
// Input // Input
config.System.EnableDockedMode.Value = EnableDockedMode; config.System.EnableDockedMode.Value = EnableDockedMode;
@ -683,10 +676,10 @@ namespace Ryujinx.Ava.UI.ViewModels
// System // System
config.System.Region.Value = (Region)Region; config.System.Region.Value = (Region)Region;
if (config.System.Language.Value != (Language)Language) if (config.System.Language.Value != (Language)Language)
GameListNeedsRefresh = true; GameListNeedsRefresh = true;
config.System.Language.Value = (Language)Language; config.System.Language.Value = (Language)Language;
if (_validTzRegions.Contains(TimeZone)) if (_validTzRegions.Contains(TimeZone))
{ {
@ -765,15 +758,13 @@ namespace Ryujinx.Ava.UI.ViewModels
config.Multiplayer.DisableP2p.Value = DisableP2P; config.Multiplayer.DisableP2p.Value = DisableP2P;
config.Multiplayer.LdnPassphrase.Value = LdnPassphrase; config.Multiplayer.LdnPassphrase.Value = LdnPassphrase;
config.Multiplayer.LdnServer.Value = LdnServer; config.Multiplayer.LdnServer.Value = LdnServer;
// Dirty Hacks // Dirty Hacks
config.Hacks.Xc2MenuSoftlockFix.Value = DirtyHacks.Xc2MenuSoftlockFix; config.Hacks.Xc2MenuSoftlockFix.Value = DirtyHacks.Xc2MenuSoftlockFix;
config.Hacks.EnableShaderTranslationDelay.Value = DirtyHacks.ShaderTranslationDelayEnabled; config.Hacks.EnableShaderTranslationDelay.Value = DirtyHacks.ShaderTranslationDelayEnabled;
config.Hacks.ShaderTranslationDelay.Value = DirtyHacks.ShaderTranslationDelay; config.Hacks.ShaderTranslationDelay.Value = DirtyHacks.ShaderTranslationDelay;
config.ToFileFormat().SaveConfig(Program.ConfigurationPath);
config.ToFileFormat().SaveConfig(Program.ConfigurationPath);
MainWindow.UpdateGraphicsConfig(); MainWindow.UpdateGraphicsConfig();
RyujinxApp.MainWindow.ViewModel.VSyncModeSettingChanged(); RyujinxApp.MainWindow.ViewModel.VSyncModeSettingChanged();

View File

@ -162,6 +162,8 @@
ValueMemberBinding="{Binding Mode=OneWay, Converter={x:Static helpers:TimeZoneConverter.Instance}}" /> ValueMemberBinding="{Binding Mode=OneWay, Converter={x:Static helpers:TimeZoneConverter.Instance}}" />
</StackPanel> </StackPanel>
<StackPanel <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Margin="0,0,0,10" Margin="0,0,0,10"
Orientation="Horizontal"> Orientation="Horizontal">
<TextBlock <TextBlock
@ -175,8 +177,11 @@
SelectedDate="{Binding CurrentDate}" SelectedDate="{Binding CurrentDate}"
ToolTip.Tip="{ext:Locale TimeTooltip}" ToolTip.Tip="{ext:Locale TimeTooltip}"
Width="350" /> Width="350" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel> </StackPanel>
<StackPanel <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Margin="250,0,0,10" Margin="250,0,0,10"
Orientation="Horizontal"> Orientation="Horizontal">
<TimePicker <TimePicker
@ -186,8 +191,12 @@
SelectedTime="{Binding CurrentTime}" SelectedTime="{Binding CurrentTime}"
Width="350" Width="350"
ToolTip.Tip="{ext:Locale TimeTooltip}" /> ToolTip.Tip="{ext:Locale TimeTooltip}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel> </StackPanel>
<StackPanel Orientation="Horizontal"> <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Orientation="Horizontal">
<TextBlock <TextBlock
VerticalAlignment="Center" VerticalAlignment="Center"
Text="{ext:Locale SettingsTabSystemSystemTimeMatch}" Text="{ext:Locale SettingsTabSystemSystemTimeMatch}"
@ -197,6 +206,7 @@
VerticalAlignment="Center" VerticalAlignment="Center"
IsChecked="{Binding MatchSystemTime}" IsChecked="{Binding MatchSystemTime}"
ToolTip.Tip="{ext:Locale MatchTimeTooltip}"/> ToolTip.Tip="{ext:Locale MatchTimeTooltip}"/>
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel> </StackPanel>
<Separator /> <Separator />
<StackPanel Margin="0,10,0,10" <StackPanel Margin="0,10,0,10"

View File

@ -26,21 +26,47 @@
Spacing="10"> Spacing="10">
<TextBlock Classes="h1" Text="{ext:Locale SettingsTabGeneralGeneral}" /> <TextBlock Classes="h1" Text="{ext:Locale SettingsTabGeneralGeneral}" />
<StackPanel Margin="10,0,0,0" Orientation="Vertical"> <StackPanel Margin="10,0,0,0" Orientation="Vertical">
<CheckBox IsChecked="{Binding EnableDiscordIntegration}"> <CheckBox
<TextBlock VerticalAlignment="Center" IsEnabled="{Binding !IsGameTitleNotNull}"
ToolTip.Tip="{ext:Locale ToggleDiscordTooltip}" Opacity="{Binding PanelOpacity}"
Text="{ext:Locale SettingsTabGeneralEnableDiscordRichPresence}" /> IsChecked="{Binding EnableDiscordIntegration}">
<StackPanel Orientation="Horizontal">
<TextBlock VerticalAlignment="Center"
ToolTip.Tip="{ext:Locale ToggleDiscordTooltip}"
Text="{ext:Locale SettingsTabGeneralEnableDiscordRichPresence}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}" />
</StackPanel>
</CheckBox> </CheckBox>
<CheckBox IsChecked="{Binding ShowConfirmExit}"> <CheckBox
<TextBlock Text="{ext:Locale SettingsTabGeneralShowConfirmExitDialog}" /> IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
IsChecked="{Binding ShowConfirmExit}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{ext:Locale SettingsTabGeneralShowConfirmExitDialog}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}" />
</StackPanel>
</CheckBox> </CheckBox>
<CheckBox IsChecked="{Binding RememberWindowState}"> <CheckBox
<TextBlock Text="{ext:Locale SettingsTabGeneralRememberWindowState}" /> IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
IsChecked="{Binding RememberWindowState}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{ext:Locale SettingsTabGeneralRememberWindowState}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}" />
</StackPanel>
</CheckBox> </CheckBox>
<CheckBox IsChecked="{Binding ShowTitleBar}" IsVisible="{x:Static helper:RunningPlatform.IsWindows}"> <CheckBox
<TextBlock Text="{ext:Locale SettingsTabGeneralShowTitleBar}" /> IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
IsChecked="{Binding ShowTitleBar}" IsVisible="{x:Static helper:RunningPlatform.IsWindows}">
<StackPanel Orientation="Horizontal">
<TextBlock Text="{ext:Locale SettingsTabGeneralShowTitleBar}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}" />
</StackPanel>
</CheckBox> </CheckBox>
<StackPanel Margin="0, 15, 0, 0" Orientation="Horizontal"> <StackPanel
Margin="0, 15, 0, 0"
Orientation="Horizontal">
<TextBlock VerticalAlignment="Center" <TextBlock VerticalAlignment="Center"
Text="{ext:Locale SettingsTabGeneralFocusLossType}" Text="{ext:Locale SettingsTabGeneralFocusLossType}"
Width="150" /> Width="150" />
@ -64,7 +90,11 @@
</ComboBoxItem> </ComboBoxItem>
</ComboBox> </ComboBox>
</StackPanel> </StackPanel>
<StackPanel Margin="0, 15, 0, 0" Orientation="Horizontal"> <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Margin="0, 15, 0, 0"
Orientation="Horizontal">
<TextBlock VerticalAlignment="Center" <TextBlock VerticalAlignment="Center"
Text="{ext:Locale SettingsTabGeneralCheckUpdatesOnLaunch}" Text="{ext:Locale SettingsTabGeneralCheckUpdatesOnLaunch}"
Width="150" /> Width="150" />
@ -81,8 +111,11 @@
<TextBlock Text="{ext:Locale SettingsTabGeneralCheckUpdatesOnLaunchBackground}" /> <TextBlock Text="{ext:Locale SettingsTabGeneralCheckUpdatesOnLaunchBackground}" />
</ComboBoxItem> </ComboBoxItem>
</ComboBox> </ComboBox>
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel> </StackPanel>
<StackPanel Margin="0, 15, 0, 0" Orientation="Horizontal"> <StackPanel
Margin="0, 15, 0, 0"
Orientation="Horizontal">
<TextBlock VerticalAlignment="Center" <TextBlock VerticalAlignment="Center"
Text="{ext:Locale SettingsTabGeneralHideCursor}" Text="{ext:Locale SettingsTabGeneralHideCursor}"
Width="150" /> Width="150" />
@ -100,7 +133,11 @@
</ComboBoxItem> </ComboBoxItem>
</ComboBox> </ComboBox>
</StackPanel> </StackPanel>
<StackPanel Margin="0, 15, 0, 10" Orientation="Horizontal"> <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Margin="0, 15, 0, 10"
Orientation="Horizontal">
<TextBlock <TextBlock
VerticalAlignment="Center" VerticalAlignment="Center"
Text="{ext:Locale SettingsTabGeneralTheme}" Text="{ext:Locale SettingsTabGeneralTheme}"
@ -118,11 +155,18 @@
<TextBlock Text="{ext:Locale SettingsTabGeneralThemeDark}" /> <TextBlock Text="{ext:Locale SettingsTabGeneralThemeDark}" />
</ComboBoxItem> </ComboBoxItem>
</ComboBox> </ComboBox>
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel> </StackPanel>
<TextBlock Foreground="{DynamicResource SecondaryTextColor}" Text="{ext:Locale SettingsTabGeneralAutoloadNote}" />
</StackPanel> </StackPanel>
<Separator Height="1" /> <Separator Height="1" />
<TextBlock Classes="h1" Text="{ext:Locale SettingsTabGeneralGameDirectories}" /> <StackPanel Orientation="Horizontal">
<TextBlock Classes="h1" Text="{ext:Locale SettingsTabGeneralGameDirectories}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel>
<StackPanel <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Margin="10,0,0,0" Margin="10,0,0,0"
HorizontalAlignment="Stretch" HorizontalAlignment="Stretch"
Orientation="Vertical" Orientation="Vertical"
@ -172,10 +216,15 @@
</StackPanel> </StackPanel>
<Separator Height="1" /> <Separator Height="1" />
<StackPanel Orientation="Vertical" Spacing="5"> <StackPanel Orientation="Vertical" Spacing="5">
<TextBlock Classes="h1" Text="{ext:Locale SettingsTabGeneralAutoloadDirectories}" /> <StackPanel Orientation="Horizontal">
<TextBlock Classes="h1" Text="{ext:Locale SettingsTabGeneralAutoloadDirectories}" />
<TextBlock Classes="globalConfigMarker" IsVisible="{Binding IsGameTitleNotNull}"/>
</StackPanel>
<TextBlock Foreground="{DynamicResource SecondaryTextColor}" Text="{ext:Locale SettingsTabGeneralAutoloadNote}" /> <TextBlock Foreground="{DynamicResource SecondaryTextColor}" Text="{ext:Locale SettingsTabGeneralAutoloadNote}" />
</StackPanel> </StackPanel>
<StackPanel <StackPanel
IsEnabled="{Binding !IsGameTitleNotNull}"
Opacity="{Binding PanelOpacity}"
Margin="10,0,0,0" Margin="10,0,0,0"
HorizontalAlignment="Stretch" HorizontalAlignment="Stretch"
Orientation="Vertical" Orientation="Vertical"

View File

@ -29,6 +29,7 @@
IsVisible="False" IsVisible="False"
KeyboardNavigation.IsTabStop="False"/> KeyboardNavigation.IsTabStop="False"/>
<Grid Name="Pages" IsVisible="False" Grid.Row="2"> <Grid Name="Pages" IsVisible="False" Grid.Row="2">
<settings:SettingsUiView Name="UiPage" />
<settings:SettingsInputView Name="InputPage" /> <settings:SettingsInputView Name="InputPage" />
<settings:SettingsSystemView Name="SystemPage" /> <settings:SettingsSystemView Name="SystemPage" />
<settings:SettingsCPUView Name="CpuPage" /> <settings:SettingsCPUView Name="CpuPage" />
@ -80,6 +81,11 @@
</ui:NavigationView.PaneHeader> </ui:NavigationView.PaneHeader>
<ui:NavigationView.MenuItems> <ui:NavigationView.MenuItems>
<ui:NavigationViewItem
IsSelected="True"
Content="{ext:Locale SettingsTabGeneral}"
Tag="UiPage"
IconSource="New" />
<ui:NavigationViewItem <ui:NavigationViewItem
Content="{ext:Locale SettingsTabInput}" Content="{ext:Locale SettingsTabInput}"
Tag="InputPage" Tag="InputPage"
@ -143,7 +149,7 @@
IsVisible="{Binding !IsGameRunning}" IsVisible="{Binding !IsGameRunning}"
Content="{ext:Locale UserProfilesDelete}" Content="{ext:Locale UserProfilesDelete}"
Command="{Binding DeleteConfigGame}" Command="{Binding DeleteConfigGame}"
Classes="red"/> Classes="global"/>
</ReversibleStackPanel> </ReversibleStackPanel>
</Grid> </Grid>
</window:StyleableAppWindow> </window:StyleableAppWindow>

View File

@ -75,6 +75,10 @@ namespace Ryujinx.Ava.UI.Windows
{ {
switch (navItem.Tag.ToString()) switch (navItem.Tag.ToString())
{ {
case nameof(UiPage):
UiPage.ViewModel = ViewModel;
NavPanel.Content = UiPage;
break;
case nameof(InputPage): case nameof(InputPage):
NavPanel.Content = InputPage; NavPanel.Content = InputPage;
break; break;

View File

@ -53,12 +53,12 @@ namespace Ryujinx.Ava.Utilities.Configuration
EnableDiscordIntegration.Value = shouldLoadFromFile ? cff.EnableDiscordIntegration : EnableDiscordIntegration.Value; // Get from global config only EnableDiscordIntegration.Value = shouldLoadFromFile ? cff.EnableDiscordIntegration : EnableDiscordIntegration.Value; // Get from global config only
CheckUpdatesOnStart.Value = shouldLoadFromFile ? cff.CheckUpdatesOnStart : CheckUpdatesOnStart.Value; // Get from global config only CheckUpdatesOnStart.Value = shouldLoadFromFile ? cff.CheckUpdatesOnStart : CheckUpdatesOnStart.Value; // Get from global config only
UpdateCheckerType.Value = shouldLoadFromFile ? cff.UpdateCheckerType : UpdateCheckerType.Value; // Get from global config only UpdateCheckerType.Value = shouldLoadFromFile ? cff.UpdateCheckerType : UpdateCheckerType.Value; // Get from global config only
FocusLostActionType.Value = shouldLoadFromFile ? cff.FocusLostActionType : FocusLostActionType.Value; // Get from global config only FocusLostActionType.Value = cff.FocusLostActionType;
ShowConfirmExit.Value = shouldLoadFromFile ? cff.ShowConfirmExit : ShowConfirmExit.Value; // Get from global config only ShowConfirmExit.Value = shouldLoadFromFile ? cff.ShowConfirmExit : ShowConfirmExit.Value; // Get from global config only
RememberWindowState.Value = shouldLoadFromFile ? cff.RememberWindowState : RememberWindowState.Value; // Get from global config only RememberWindowState.Value = shouldLoadFromFile ? cff.RememberWindowState : RememberWindowState.Value; // Get from global config only
ShowTitleBar.Value = shouldLoadFromFile ? cff.ShowTitleBar : ShowTitleBar.Value; // Get from global config only ShowTitleBar.Value = shouldLoadFromFile ? cff.ShowTitleBar : ShowTitleBar.Value; // Get from global config only
EnableHardwareAcceleration.Value = shouldLoadFromFile ? cff.EnableHardwareAcceleration : EnableHardwareAcceleration.Value; // Get from global config only EnableHardwareAcceleration.Value = shouldLoadFromFile ? cff.EnableHardwareAcceleration : EnableHardwareAcceleration.Value; // Get from global config only
HideCursor.Value = shouldLoadFromFile ? cff.HideCursor : HideCursor.Value; // Get from global config only HideCursor.Value = cff.HideCursor;
Logger.EnableFileLog.Value = cff.EnableFileLog; Logger.EnableFileLog.Value = cff.EnableFileLog;
Logger.EnableDebug.Value = cff.LoggingEnableDebug; Logger.EnableDebug.Value = cff.LoggingEnableDebug;