Skip to content

Commit 83f02f5

Browse files
committed
Use log error & Improve returned color
1 parent 5c16b86 commit 83f02f5

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Flow.Launcher/Helper/WallpaperPathRetrieval.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ public static Brush GetWallpaperBrush()
3232
var wallpaperPath = Win32Helper.GetWallpaperPath();
3333
if (string.IsNullOrEmpty(wallpaperPath) || !File.Exists(wallpaperPath))
3434
{
35-
App.API.LogInfo(ClassName, $"Wallpaper path is invalid: {wallpaperPath}");
35+
App.API.LogError(ClassName, $"Wallpaper path is invalid: {wallpaperPath}");
3636
var wallpaperColor = GetWallpaperColor();
3737
return new SolidColorBrush(wallpaperColor);
3838
}
@@ -61,7 +61,8 @@ public static Brush GetWallpaperBrush()
6161
if (originalWidth == 0 || originalHeight == 0)
6262
{
6363
App.API.LogError(ClassName, $"Failed to load bitmap: Width={originalWidth}, Height={originalHeight}");
64-
return new SolidColorBrush(Colors.Transparent);
64+
var wallpaperColor = GetWallpaperColor();
65+
return new SolidColorBrush(wallpaperColor);
6566
}
6667

6768
// Calculate the scaling factor to fit the image within 800x600 while preserving aspect ratio

0 commit comments

Comments
 (0)