ActivityWatch / aw-watcher-window-wayland

Window and AFK watcher for some Wayland compositors
Mozilla Public License 2.0
57 stars 14 forks source link

migrate wayland-rs to 0.31 #32

Open cjc7373 opened 10 months ago

cjc7373 commented 10 months ago

This is a major refactor and not finished yet.. But it's workable under sway and I think it's time to get some feedback.

Basically we need to implement a Dispatch trait for every event. There's macro delegate_noop to ignore irrelevant events.

Also wayland-protocols-wlr and wayland-protocols-plasma crate offer the interfaces we need, so there's no need to generate some bindings manually.

2e3s commented 9 months ago

I recommend that you implement this instead of kwin-idle https://wayland.app/protocols/ext-idle-notify-v1 You could copy from https://github.com/2e3s/awatcher/blob/main/watchers/src/watchers/wl_ext_idle_notify.rs

cjc7373 commented 9 months ago

Sure, if this PR can be accepted, I definitely want to implement that.