Fix for reflection-based configuration

This commit is contained in:
Brandon Thetford
2024-02-16 16:05:03 -07:00
parent 3cd0832cb0
commit e7b228a2c8
2 changed files with 4 additions and 1 deletions

View File

@@ -63,7 +63,8 @@ public sealed class Colors : INotifyCollectionChanged, IDictionary<string, Color
/// </remarks>
[SerializableConfigurationProperty (Scope = typeof (ThemeScope), OmitClassName = true)]
[JsonConverter (typeof (DictionaryJsonConverter<ColorScheme?>))]
public static Dictionary<string, ColorScheme?> ColorSchemes { get; }
[UsedImplicitly]
public static Dictionary<string, ColorScheme?> ColorSchemes { get; private set; }
/// <inheritdoc/>
public IEnumerator<KeyValuePair<string, ColorScheme?>> GetEnumerator () { return ColorSchemes.GetEnumerator (); }

View File

@@ -38,6 +38,7 @@
<!-- Dependencies -->
<!-- =================================================================== -->
<ItemGroup>
<PackageReference Include="JetBrains.Annotations" Version="2023.3.0" />
<PackageReference Include="Microsoft.NETFramework.ReferenceAssemblies" Version="1.0.3" PrivateAssets="all" />
<PackageReference Include="System.IO.Abstractions" Version="20.0.4" />
<PackageReference Include="System.Text.Json" Version="8.0.1" />
@@ -83,6 +84,7 @@
</ItemGroup>
<ItemGroup>
<Using Include="System.Text" />
<Using Include="JetBrains.Annotations" />
</ItemGroup>
<!-- =================================================================== -->
<!-- Nuget -->