ui(client): formatting & code improvements

This commit is contained in:
2025-11-07 15:22:28 +01:00
parent 4baf571713
commit 1c070891f1
3 changed files with 13 additions and 16 deletions

View File

@@ -62,9 +62,9 @@ public partial class MainForm : Window
{
loadingData = true;
TextBoxMinecraftProfileFolder.Text = modpackInfo?.LocaLPath ?? AppConfig.Instance.LastMinecraftProfilePath ?? TextBoxMinecraftProfileFolder.Text;
TextBoxModpackConfig.Text = modpackInfo?.ConfigUrl ?? TextBoxModpackConfig.Text;
TextBoxInstallKey.Text = modpackInfo?.ExtrasKey ?? TextBoxInstallKey.Text;
TextBoxMinecraftProfileFolder.Text = modpackInfo.LocaLPath ?? AppConfig.Instance.LastMinecraftProfilePath ?? TextBoxMinecraftProfileFolder.Text;
TextBoxModpackConfig.Text = modpackInfo.ConfigUrl ?? TextBoxModpackConfig.Text;
TextBoxInstallKey.Text = modpackInfo.ExtrasKey ?? TextBoxInstallKey.Text;
loadingData = false;
}
@@ -186,9 +186,6 @@ public partial class MainForm : Window
if (Debugger.IsAttached)
throw;
}
finally
{
}
}
// Error while update check
@@ -263,7 +260,7 @@ public partial class MainForm : Window
private async void MainForm_Loaded(object? sender, RoutedEventArgs e)
{
var updater = new AppUpdater(Program.UPDATE_URL);
var updater = new AppUpdater(Program.UpdateUrl);
if (await updater.Check() && await MessageBoxManager.GetMessageBoxStandard(MsgBoxLangRes.UpdateAvailable_Title, MsgBoxLangRes.UpdateAvailable, ButtonEnum.YesNo).ShowWindowDialogAsync(this) == ButtonResult.Ok)
{
SetStatus(GeneralLangRes.DownloadProgramUpdate, Symbols.Fluent.GetImageSource(SymbolsFluent.software_installer));