Ryochan7 / sc-controller

User-mode driver and GTK3 based GUI for Steam Controller
GNU General Public License v2.0
177 stars 23 forks source link

Fix wayland overlay submenu layering and positioning #51

Closed Supreeeme closed 2 years ago

Supreeeme commented 2 years ago

For some reason, the ordering of surfaces in a single layer is undefined in the Wayland layer shell protocol, so this leads to the overlay layering acting differently on Sway and KDE. On Sway, the last opened menu is on the bottom, meaning that it will be hidden behind an older window, which is obviously not wanted. This is a somewhat hacky fix to work around that, essentially putting the last opened submenu in the highest layer and every other submenu in the lower layer. In the mean time I opened an issue in the wlroots protocol repository to hopefully get some way of setting arbitrary orders within a single layer into the protocol. Also a less hacky fix for the menu positioning and updating the readme to mention GTK Layer Shell for overlays/menus on wayland.

Ryochan7 commented 2 years ago

Haven't been hanging around here enough. Didn't see this pull request until yesterday. The changes look good and they have been merged in. Thank you.