johannesjo / gnome-shell-extension-window-session-manager

An indicator that let's you save and restore your open apps and the window positions and arrangements over multiple real and virtual displays.
MIT License
91 stars 18 forks source link

Is Wayland compatibility in the plans? #9

Open NinjaTurtle007 opened 6 years ago

NinjaTurtle007 commented 6 years ago

Are there plans to make this wonderful extension work on Wayland or are there any alternatives for it?

johannesjo commented 6 years ago

Theoretically yes. But unfortunately this either is not possible to achieve atm due to Wayland's limitations or I'm too stupid to find out how. I dug around the docs for quite a while, but was unable to find any angle how to tackle this problem and gave up. When Ubuntu finally moves to Wayland, I probably give it another go but until then the tool will only work with XWayland applications. I'm glad for any help and pull requests are very welcome of course.

damianmoore commented 1 year ago

Another route to achieving this, rather than communicating with Wayland, could be to connect to 'org.gnome.Shell' via DBus and listen to events happening there. I'm trying something similar but haven't had much luck yet.

damianmoore commented 1 year ago

I found this PR for a Python-based activity monitor quite interesting: https://github.com/ActivityWatch/aw-watcher-window/pull/46/files

It appears once you have a Gnome Shell GObject (might be wrong terminology) you can get it to evaluate JS for you that can introspect the functions/data structures of Gnome Shell itself.