@@ -22,7 +22,7 @@ public static class ImageLoader
22
22
private static Lock storageLock { get ; } = new ( ) ;
23
23
private static BinaryStorage < List < ( string , bool ) > > _storage ;
24
24
private static readonly ConcurrentDictionary < string , string > GuidToKey = new ( ) ;
25
- private static IImageHashGenerator _hashGenerator ;
25
+ private static ImageHashGenerator _hashGenerator ;
26
26
private static readonly bool EnableImageHash = true ;
27
27
public static ImageSource Image => ImageCache [ Constant . ImageIcon , false ] ;
28
28
public static ImageSource MissingImage => ImageCache [ Constant . MissingImgIcon , false ] ;
@@ -31,7 +31,7 @@ public static class ImageLoader
31
31
public const int FullIconSize = 256 ;
32
32
public const int FullImageSize = 320 ;
33
33
34
- private static readonly string [ ] ImageExtensions = { ".png" , ".jpg" , ".jpeg" , ".gif" , ".bmp" , ".tiff" , ".ico" } ;
34
+ private static readonly string [ ] ImageExtensions = [ ".png" , ".jpg" , ".jpeg" , ".gif" , ".bmp" , ".tiff" , ".ico" ] ;
35
35
private static readonly string SvgExtension = ".svg" ;
36
36
37
37
public static async Task InitializeAsync ( )
@@ -327,7 +327,7 @@ public static async ValueTask<ImageSource> LoadAsync(string path, bool loadFullI
327
327
return img ;
328
328
}
329
329
330
- private static ImageSource LoadFullImage ( string path )
330
+ private static BitmapImage LoadFullImage ( string path )
331
331
{
332
332
BitmapImage image = new BitmapImage ( ) ;
333
333
image . BeginInit ( ) ;
@@ -364,7 +364,7 @@ private static ImageSource LoadFullImage(string path)
364
364
return image ;
365
365
}
366
366
367
- private static ImageSource LoadSvgImage ( string path , bool loadFullImage = false )
367
+ private static RenderTargetBitmap LoadSvgImage ( string path , bool loadFullImage = false )
368
368
{
369
369
// Set up drawing settings
370
370
var desiredHeight = loadFullImage ? FullImageSize : SmallIconSize ;
0 commit comments