From 7baa065138996047420458551bc565daae8ba157 Mon Sep 17 00:00:00 2001 From: lasedark Date: Sun, 4 Apr 2021 13:32:36 +0800 Subject: [PATCH 1/2] Use KanColleClient.Current origin instead of Models --- EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs b/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs index 5c91f21..0f9cc4b 100644 --- a/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs +++ b/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs @@ -34,11 +34,11 @@ public SettingsViewModel() private void Initialize() { this.BossSettings.MapItemsSource - = Models.Maps.MapInfos + = KanColleClient.Current.Master.MapInfos .Where(x => 20 < x.Value.MapAreaId) .Select(x => x.Value) .Select(x => new KeyValuePair(x.Id, $"{x.MapAreaId}-{x.IdInEachMapArea} : {x.Name} - {x.OperationName}")) - .ToArray(); + .ToArray(); this.BossSettings.IsEnabled = true; this.TpSettings.Settings.UpdateFromMaster(); From 472bd5601332148ca053b76499bbc2e7e469a346 Mon Sep 17 00:00:00 2001 From: lasedark Date: Sun, 4 Apr 2021 16:40:14 +0800 Subject: [PATCH 2/2] code formatting --- EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs b/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs index 0f9cc4b..99055bc 100644 --- a/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs +++ b/EventMapHpViewer/ViewModels/Settings/SettingsViewModel.cs @@ -38,7 +38,7 @@ private void Initialize() .Where(x => 20 < x.Value.MapAreaId) .Select(x => x.Value) .Select(x => new KeyValuePair(x.Id, $"{x.MapAreaId}-{x.IdInEachMapArea} : {x.Name} - {x.OperationName}")) - .ToArray(); + .ToArray(); this.BossSettings.IsEnabled = true; this.TpSettings.Settings.UpdateFromMaster();