gui refactor.

This commit is contained in:
lhhxxxxx
2022-06-05 18:05:06 +08:00
parent f640bba867
commit 97afa5befb
3 changed files with 5 additions and 5 deletions

View File

@@ -681,7 +681,7 @@ namespace MeoAsstGui
return AsstAppendTaskWithEncoding("Award");
}
public bool AsstAppendStartUp(int server_type, bool enable)
public bool AsstAppendStartUp(string server_type, bool enable)
{
var task_params = new JObject();
task_params["server_type"] = server_type;

View File

@@ -136,8 +136,8 @@ namespace MeoAsstGui
ServerTypeList = new List<CombData>
{
new CombData { Display = "官服", Value = "0" },
new CombData { Display = "Bilibili服", Value = "1" }
new CombData { Display = "官服", Value = "Official" },
new CombData { Display = "Bilibili服", Value = "Bilibili" }
};
}
@@ -166,7 +166,7 @@ namespace MeoAsstGui
}
}
private string _serverType = ViewStatusStorage.Get("Start.ServerType", "0");
private string _serverType = ViewStatusStorage.Get("Start.ServerType", "Official");
public string ServerType
{

View File

@@ -331,7 +331,7 @@ namespace MeoAsstGui
{
var settings = _container.Get<SettingsViewModel>();
var asstProxy = _container.Get<AsstProxy>();
int.TryParse(settings.ServerType, out var mode);
var mode = settings.ServerType;
var enable = settings.StartGameEnable;
return asstProxy.AsstAppendStartUp(mode, enable);
}