Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Wayland support #32

Closed
AndrewAmmerlaan opened this issue Aug 25, 2022 · 4 comments
Closed

Wayland support #32

AndrewAmmerlaan opened this issue Aug 25, 2022 · 4 comments

Comments

@AndrewAmmerlaan
Copy link

Currently spotify-tray does not work properly under wayland (KDE), It fails to launch because it does not detect an X11 display:

andrew@andrew-gentoo-pc ~ % spotify-tray

** (spotify-tray:12962): CRITICAL **: 13:28:57.778: No X11 display found. Quitting.

This can be worked around with GDK_BACKEND=x11. However when launching with this variable the icon in the system tray is not properly clickable, it sometimes works (as in opens and closes spotify) but more often does nothing.

@tsmetana
Copy link
Owner

The error message you posted means spotify-tray actually works properly (i.e. as designed) under Wayland: it can't work there so it refuses to start -- fix from the commit a7a2968. I'll take a look what GDK_BACKEND impacts in Wayland, but don't hope I'll make it work -- I rely on X too much for the core functionality.
Thanks for reporting.

@AndrewAmmerlaan
Copy link
Author

I'll take a look what GDK_BACKEND impacts in Wayland

GDK_BACKEND=x11 runs the application in the X11 compatibility mode (xwayland). It allows running legacy X11 applications in a wayland session, which usually works fine but apparently not for spotify-tray.

That applications running via xwayland don't properly interact with the system tray is probably also a bug in KDE Plasma (in fact I think it is this one: https://bugs.kde.org/show_bug.cgi?id=433079 Hopefully when this gets fixed spotify-tray will be somewhat usable in a wayland session using the GDK_BACKEND=x11 workaround).
Anyway, it would be nice if at some point spotify-tray would work on wayland without having to explicitly run it via xwayland.

@kopr12
Copy link

kopr12 commented Aug 30, 2022

Currently spotify-tray does not work properly under wayland (KDE), It fails to launch because it does not detect an X11 display:

That might work on KDE because they use xembed-sni-proxy, but in other WM's under Wayland the icon isn't showing in the tray (with GDK_BACKEND=x11)
I had to make my own, I don't know how this one works, but in my version you have the icon in the tray and 4 actions in the menu when you right click on it, Play/Pause, Previous track, Next track and Quit. Single click on it with the left click does the Play/Pause.

I didn't upload it yet, if you're interested let me know and I will.

@tsmetana
Copy link
Owner

OK. I don't think I can do much about this. Closing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants