mirror of
https://github.com/djibux/BoilR.git
synced 2026-09-01 05:53:41 +02:00
Download image names based on mime type (#124)
This commit is contained in:
@@ -150,10 +150,13 @@ fn fix_shortcut_icons(
|
||||
&shortcut.exe,
|
||||
&shortcut.app_name,
|
||||
);
|
||||
shortcut.icon = image_folder
|
||||
.join(image_type.file_name(app_id))
|
||||
.to_string_lossy()
|
||||
.to_string();
|
||||
for ext in ["ico", "png", "jpg", "webp"] {
|
||||
let path = image_folder.join(image_type.file_name(app_id, ext));
|
||||
if path.exists() {
|
||||
shortcut.icon = path.to_string_lossy().to_string();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user