添加语言功能及相关设置
This commit is contained in:
commit
3d64a4474d
11 files changed
+119
-6
No files matched your search
@@ -26,6 +26,7 @@ using System.Windows.Threading;
|
||||
using System.Xml.Linq;
|
||||
using TouchSocket.Core;
|
||||
using TouchSocket.Sockets;
|
||||
using System.Speech.Synthesis;
|
||||
using static MaterialDesignThemes.Wpf.Theme;
|
||||
using static SunlightCentralizedControlManagement_SCCM_.UserClass.SqliteHelper;
|
||||
using static System.Net.WebRequestMethods;
|
||||
@@ -75,7 +76,8 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
||||
public static UserControls.info[] inf = new UserControls.info[999]; //定义总览信息卡
|
||||
public static int ERR_c = 0;//错误计数器
|
||||
public static bool[] USER_Capacity { set; get; } = new bool[99];
|
||||
|
||||
private SpeechSynthesizer synth = new SpeechSynthesizer();//语音
|
||||
|
||||
public MainWindowViewModel()
|
||||
{
|
||||
try
|
||||
@@ -88,6 +90,9 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
||||
SN_ID = Configini.IniReadvalue("SN", "SN2");
|
||||
SN_KEY = Configini.IniReadvalue("SN", "SN1");
|
||||
DyelotsDispenser = Convert.ToBoolean(Configini.IniReadvalue("SYS", "DyelotsDispenser"));
|
||||
|
||||
synth.Rate = int.Parse( Configini.IniReadvalue("VOICE", "V1"));
|
||||
synth.Volume = int.Parse( Configini.IniReadvalue("VOICE", "V2"));
|
||||
}
|
||||
catch (Exception ex) { LogGing.ERRDATA(ex); }
|
||||
|
||||
@@ -411,8 +416,7 @@ namespace SunlightCentralizedControlManagement_SCCM_.ViewModel
|
||||
{
|
||||
LogGing.LogGingDATA("SDTD:" + ex.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
public static DataTable dt_d = new DataTable("DIO");
|
||||
public static DataTable dt_a = new DataTable("AIO");
|
||||
|
||||
Reference in new issue
Block a user