We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 83f02f5 commit 60ec9b5Copy full SHA for 60ec9b5
Flow.Launcher/Helper/WallpaperPathRetrieval.cs
@@ -75,7 +75,9 @@ public static Brush GetWallpaperBrush()
75
// Set DecodePixelWidth and DecodePixelHeight to resize the image while preserving aspect ratio
76
var bitmap = new BitmapImage();
77
bitmap.BeginInit();
78
+ bitmap.CacheOption = BitmapCacheOption.OnLoad; // Use OnLoaded to ensure the wallpaper file is not locked
79
bitmap.UriSource = new Uri(wallpaperPath);
80
+ bitmap.CreateOptions = BitmapCreateOptions.IgnoreColorProfile;
81
bitmap.DecodePixelWidth = decodedPixelWidth;
82
bitmap.DecodePixelHeight = decodedPixelHeight;
83
bitmap.EndInit();
0 commit comments