diff --git a/source/SkiaSharp.Extended.UI.Maui/Utils/ResourceLoader.shared.cs b/source/SkiaSharp.Extended.UI.Maui/Utils/ResourceLoader.shared.cs index f199725a..8c12ed0d 100644 --- a/source/SkiaSharp.Extended.UI.Maui/Utils/ResourceLoader.shared.cs +++ b/source/SkiaSharp.Extended.UI.Maui/Utils/ResourceLoader.shared.cs @@ -3,12 +3,9 @@ internal static class ResourceLoader where T : ResourceDictionary, new() { - private static bool registered; - internal static void EnsureRegistered(VisualElement? element = null) { - if (registered) - return; + bool registered = false; // try register with the current app var merged = Application.Current?.Resources?.MergedDictionaries;