filips123 / PWAsForFirefox

A tool to install, manage and use Progressive Web Apps (PWAs) in Mozilla Firefox
https://pwasforfirefox.filips.si
Mozilla Public License 2.0
2.27k stars 52 forks source link

macOS task switchers always show the Firefox icon #483

Open finite-state-machine opened 7 months ago

finite-state-machine commented 7 months ago

Description

Third-party app switchers for macOS (e.g., Contexts^1, AltTab^2) always show the Firefox icon rather than the correct icon for the PWA (the site's favicon, shown correctly in the dock).

Steps to Reproduce

  1. Install a third-party app switcher such as Contexts^1 or AltTab^2
  2. Install and launch Firefox and one or more PWAs (almost any site with a favicon will do)
  3. Use the third-party switcher
  4. Observe that Firefox and all PWAs have the same icon, i.e., Firefox's logo

Presumably, since every third-party switcher I've tried has the same behaviour, this is a problem with FirefoxPWA rather than the switchers.

macOS dock (works; expected behaviour)

Screenshot 2024-03-21 at 09 23 11

The macOS ⌘+tab switcher also shows the correct icons.

Contexts

Screenshot 2024-03-21 at 09 15 25

Alt-Tab

2024-03-21 partial screenshot

Additional Information

I haven't attached logs as I judge these unlikely to help.

Affected Websites

Environment

filips123 commented 7 months ago

Do these task switchers use some different API to get the window icons? Currently, PWAsForFirefox just creates an app bundle with the web app icon and launches Firefox from within that bundle. So, maybe there also exists another API to set the icon that task switchers use?

However, I don't know much about macOS development so I probably won't be able to fix this anytime soon.

finite-state-machine commented 7 months ago

Sorry I've been quiet on this. I don't have any more information about how the app icons are retrieved, nor am I in any way a macOS developer. My next step would be to read the source for AltTab.

I've paused my use of PWAsForFirefox for the time being. I love the idea, but I found it a little unstable for day-to-day use.