mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-28 07:22:50 -05:00
feat: map steam_app_ID to steam_icon_ID for actual game icons (#1312)
Steam Proton games use window class steam_app_XXXXX. Steam installs icons as steam_icon_XXXXX. This maps between them so actual game icons display instead of generic controller fallback.
This commit is contained in:
@@ -59,6 +59,9 @@ Singleton {
|
||||
return "transmission";
|
||||
return "transmission-gtk";
|
||||
}
|
||||
const steamMatch = appId.match(/^steam_app_(\d+)$/);
|
||||
if (steamMatch)
|
||||
return `steam_icon_${steamMatch[1]}`;
|
||||
return appId;
|
||||
}
|
||||
|
||||
@@ -68,8 +71,8 @@ Singleton {
|
||||
}
|
||||
|
||||
const moddedId = moddedAppId(appId);
|
||||
if (moddedId.toLowerCase().includes("steam_app")) {
|
||||
return "";
|
||||
if (moddedId.startsWith("steam_icon_")) {
|
||||
return Quickshell.iconPath(moddedId, true);
|
||||
}
|
||||
|
||||
return desktopEntry && desktopEntry.icon ? Quickshell.iconPath(desktopEntry.icon, true) : "";
|
||||
|
||||
Reference in New Issue
Block a user