diff --git a/Ethereal.FAF.UI.Client/Infrastructure/Services/ApplicationHostService.cs b/Ethereal.FAF.UI.Client/Infrastructure/Services/ApplicationHostService.cs index ef8701b..88ad677 100644 --- a/Ethereal.FAF.UI.Client/Infrastructure/Services/ApplicationHostService.cs +++ b/Ethereal.FAF.UI.Client/Infrastructure/Services/ApplicationHostService.cs @@ -93,9 +93,13 @@ private async Task HandleActivationAsync() await _settingsManager.LoadAsync(); _navigationWindow.ShowWindow(); - if (_settingsManager.Settings.SelectedFaServer == null) + if (!_settingsManager.Settings.ClientInitialized) { - _navigationWindow.Navigate(typeof(SelectServerView)); + _navigationWindow.Navigate(typeof(PrepareClientView)); + } + else if (_settingsManager.Settings.SelectedFaServer == null) + { + _navigationWindow.Navigate(typeof(SelectServerView)); } else { diff --git a/Ethereal.FAF.UI.Client/Models/Settings/Settings.cs b/Ethereal.FAF.UI.Client/Models/Settings/Settings.cs index 20b5250..1c60947 100644 --- a/Ethereal.FAF.UI.Client/Models/Settings/Settings.cs +++ b/Ethereal.FAF.UI.Client/Models/Settings/Settings.cs @@ -16,6 +16,7 @@ public class Settings : JsonSettings, INotifyPropertyChanged public virtual UpdateChannel PreferredUpdateChannel { get; set; } = UpdateChannel.Stable; + public virtual bool ClientInitialized { get; set; } public virtual bool RememberSelectedFaServer { get; set; } = true; diff --git a/Ethereal.FAF.UI.Client/ViewModels/PrepareClientViewModel.cs b/Ethereal.FAF.UI.Client/ViewModels/PrepareClientViewModel.cs index 4ede118..62605ad 100644 --- a/Ethereal.FAF.UI.Client/ViewModels/PrepareClientViewModel.cs +++ b/Ethereal.FAF.UI.Client/ViewModels/PrepareClientViewModel.cs @@ -2,6 +2,7 @@ using CommunityToolkit.Mvvm.ComponentModel; using CommunityToolkit.Mvvm.Input; using Ethereal.FAF.UI.Client.Infrastructure.Helper; +using Ethereal.FAF.UI.Client.Infrastructure.Services; using Ethereal.FAF.UI.Client.Infrastructure.Services.Interfaces; using Ethereal.FAF.UI.Client.Infrastructure.Utils; using Ethereal.FAF.UI.Client.Models.Progress; @@ -258,6 +259,8 @@ private void LoadFiles() { if (x.IsCompletedSuccessfully) { + _settingsManager.Settings.ClientInitialized = true; + _settingsManager.Settings.Save(); App.Current.Dispatcher.Invoke(() => _navigationWindow.Navigate(typeof(AuthView))); } }).SafeFireAndForget();