From d3332c9ffb16cde59c21301b4b3e3adba4b0f39e Mon Sep 17 00:00:00 2001 From: sunhonglei Date: Wed, 25 Dec 2024 13:44:20 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20filepath=E7=9B=B8=E5=85=B3=E4=BF=AE?= =?UTF-8?q?=E6=AD=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ViewModel/Configuration/SettingsPages/SettingsVM.cs | 6 +++++- Views/Configuration/SettingPages/CustomSettingPage.xaml | 2 +- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/ViewModel/Configuration/SettingsPages/SettingsVM.cs b/ViewModel/Configuration/SettingsPages/SettingsVM.cs index 0ef25df..d1795d9 100644 --- a/ViewModel/Configuration/SettingsPages/SettingsVM.cs +++ b/ViewModel/Configuration/SettingsPages/SettingsVM.cs @@ -61,6 +61,10 @@ namespace SparkClient.ViewModel.Configuration.SettingsPages Languages.Rows.Add("中文", "zh-cn"); Languages.Rows.Add("English", "en"); LanguageId = Settings.SelectValueByName("LanguageId"); + if (LanguageId.Length == 0) + { + LanguageId = "zh-cn"; + } bool.TryParse( Settings.SelectValueByName("TxtFileChecked"), out bool TxtFileChecked); this.TxtFileChecked = TxtFileChecked; bool.TryParse(Settings.SelectValueByName("StlFileChecked"), out bool StlFileChecked); @@ -227,7 +231,7 @@ namespace SparkClient.ViewModel.Configuration.SettingsPages } else { - return "zh-cn"; + return ""; } } } diff --git a/Views/Configuration/SettingPages/CustomSettingPage.xaml b/Views/Configuration/SettingPages/CustomSettingPage.xaml index e8b1c5f..fa4b9c3 100644 --- a/Views/Configuration/SettingPages/CustomSettingPage.xaml +++ b/Views/Configuration/SettingPages/CustomSettingPage.xaml @@ -117,7 +117,7 @@ - +