mirror of
https://github.com/BeyondDimension/SteamTools.git
synced 2026-10-20 00:11:04 +08:00
fix
This commit is contained in:
@@ -244,7 +244,7 @@ namespace System.Application.UI
|
||||
desktop.MainWindow = null;
|
||||
else
|
||||
#endif
|
||||
desktop.MainWindow = MainWindow;
|
||||
desktop.MainWindow = MainWindow;
|
||||
|
||||
desktop.Startup += Desktop_Startup;
|
||||
desktop.Exit += ApplicationLifetime_Exit;
|
||||
@@ -268,7 +268,7 @@ namespace System.Application.UI
|
||||
if (Startup.IsMainProcess)
|
||||
{
|
||||
Startup.ActiveUserPost(ActiveUserType.OnStartup);
|
||||
IAppUpdateService.Instance.CheckUpdate();
|
||||
IAppUpdateService.Instance.CheckUpdate(showIsExistUpdateFalse: false);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -53,7 +53,8 @@ namespace System.Application.Services
|
||||
/// 检查更新,返回新版本信息
|
||||
/// </summary>
|
||||
/// <param name="force">是否强制检查,如果为 <see langword="false"/> 当有新版本内存中缓存时将跳过 api 请求</param>
|
||||
void CheckUpdate(bool force = false);
|
||||
/// <param name="showIsExistUpdateFalse">是否显示已是最新版本吐司提示</param>
|
||||
void CheckUpdate(bool force = false, bool showIsExistUpdateFalse = true);
|
||||
|
||||
ICommand StartUpdateCommand { get; }
|
||||
}
|
||||
|
||||
@@ -65,7 +65,7 @@ namespace System.Application.Services.Implementation
|
||||
|
||||
static bool isCheckUpdateing;
|
||||
|
||||
public async void CheckUpdate(bool force)
|
||||
public async void CheckUpdate(bool force, bool showIsExistUpdateFalse = true)
|
||||
{
|
||||
if (!force && IsExistUpdate)
|
||||
{
|
||||
@@ -102,7 +102,7 @@ namespace System.Application.Services.Implementation
|
||||
if (!rsp.Content.HasValue())
|
||||
{
|
||||
IsExistUpdate = false;
|
||||
toast.Show(SR.IsExistUpdateFalse);
|
||||
if (showIsExistUpdateFalse) toast.Show(SR.IsExistUpdateFalse);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
@@ -285,7 +285,7 @@ namespace System.Application.Services.CloudService
|
||||
{
|
||||
if (isApi)
|
||||
{
|
||||
if (response is IApiResponse<IExplicitHasValue> explicitHasValue && !explicitHasValue.Content.HasValue())
|
||||
if (!responseContentMaybeNull && response is IApiResponse<IExplicitHasValue> explicitHasValue && !explicitHasValue.Content.HasValue())
|
||||
{
|
||||
response.Code = ApiResponseCode.NoResponseContentValue;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user