itchio / itch

🎮 The best way to play your itch.io games
https://itch.io/app
MIT License
2.35k stars 209 forks source link

🐧 Games Locked to Launcher Disappear on Reboot #1088

Closed niedzielski closed 6 years ago

niedzielski commented 7 years ago

itch v21.0.4 on Ubuntu v16.10

Open itch

Launch Tiled or another app

Right click on the program icon and click "lock to launcher"

The app launcher icon persists for the length of the session. On reboot, the app launcher icon disappears. Supporting consistent desktop icon access is an important workflow for often used programs

fasterthanlime commented 7 years ago

Seems more like a Unity (the ubuntu dock) bug than an app bug. I'm interested in any workarounds we can find though!

Maybe it's because those games don't have a .desktop file ?

niedzielski commented 7 years ago

When I pin an app, Unity should create a .desktop entry in ~/.local/share/applications. Here's one it created after I launched and pinned "Salvage Solitude 8140" from itch:

[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Name=Salvage Solitude 8140 Configuration
Icon=salvagesolitude8140v0_6_x86_64.png
Path=/home/stephen/.config/itch/apps/Salvage Solitude 8140/SalvageSolitude8140v0.6 - Linux
Exec=/home/stephen/.config/itch/apps/Salvage Solitude 8140/SalvageSolitude8140v0.6 - Linux/SalvageSolitude8140v0.6.x86_64
StartupNotify=false
StartupWMClass=SalvageSolitude8140v0.6.x86_64
OnlyShowIn=Unity;
X-UnityGenerated=true

I think the executable path must valid for the shortcut to appear in a new session. Maybe Unity is just choking on the spaces? In some cases, it seems the .desktop file is not made but I do not know why. Since Unity is the default window manager on Ubuntu, I would think that regardless of Unity's warts and shortcomings, itch should strive to support it well out of the box.

fasterthanlime commented 7 years ago

Maybe Unity is just choking on the spaces?

It looks like it's generating an invalid .desktop file indeed - spaces need to be escaped, see http://askubuntu.com/questions/189822/how-to-escape-spaces-in-desktop-files-exec-line

I would think that regardless of Unity's warts and shortcomings, itch should strive to support it well out of the box.

I agree - but also, if Unity is bugged, we should report it upstream and have it fix their bug, not strip itch of a feature (having install folders be based on game names, spaces and all)

niedzielski commented 7 years ago

Cool, I've created an upstream report here: https://bugs.launchpad.net/ubuntu/+source/unity/+bug/1652402

fasterthanlime commented 7 years ago

Awesome, thanks for following up!