seafile-client/data
Reilly Brogan 69b1e05156
Fix wayland window associations by renaming .desktop file (#1570)
For Wayland window managers to correctly associate open windows with the corresponding .desktop file the name of the `.desktop` file sans `.desktop` suffix needs to match the window appId.

By default Qt sets the appId to the name of the binary, but `QCoreApplication::setOrganizationDomain("seafile.com");` in `src/main.cpp` causes it to use the domain to create a fully qualified appId (`com.seafile.seafile-applet`). This does not match the desktop file `seafile.desktop`, which causes open windows to not be correctly associated with the launcher. While it's possible to use `QGuiApplication::setDesktopFileName()` to override the appId it's more consistent with FreeDesktop specs to use the fully qualified appId instead.

To see the difference this makes it is sufficient to start seafile-applet in a Plasma Wayland session (which has easily accessible window property introspection tools) with and without `com.seafile.seafile-applet.desktop` being the name of the `.desktop` file. Without the window will show the generic Wayland icon in the overview, with it will show the seafile icon shipped in the package.

Resolves haiwen/seafile-client#1568 (probably)
2024-12-21 10:35:08 +08:00
..
icons Updated seafile.svg file. 2017-08-10 10:34:14 +08:00
com.seafile.seafile-applet.desktop Fix wayland window associations by renaming .desktop file (#1570) 2024-12-21 10:35:08 +08:00