Open lessu opened 3 months ago
not atm
@lessu @vaxerski so since that subject was brought again, I will confess that I actually started to implement that on my own some time ago, to have a proper support for tools that are currently requring that portal such as InputLeap.
This is my current effort: https://github.com/hyprwm/xdg-desktop-portal-hyprland/commit/a8553decae5a109135bfa4f719d8a6037eb3fcd7
Which is not even close to finish, contains a lot of bloat and is violating a lot of rules, but what I already have in there is a RemoteDesktop
basic implementation with a support for basic mouse movements, as well as a seperate small application named hyprland-eis
which is based on emulated input server example from libei, and that is because tools such as InputLeap
are only using RemoteDesktop portal to connect to device, and then there's a method which is only returning a file descriptor to the emulated input server socket, through which all the actual traffic so mouse movements, key presses etc. is being served. Also since this is my use case it's the easiest way for me to test the whole thing.
All together, I currently do have it in the state in which I can create a working connection between InputLeap/Barrier server and to connect to my Hyprland based InputLeap client, I can then also move the mouse freely between these two targets, which already I think is quite a lot. Currently struggling a bit with a keyboard presses, mostly due to all the xkb specific quirks, but I think I am getting there as well.
That being said, C/C++ are almost completely unknown languages to me, and I am learning while coding that piece of code, and I am doing that mostly because there are no other volunteers and I need it for my life to be fully comfortable. So in general a quality of that (especially currently since it's simply work in progress experiment) is terrible... but hey, it works (at least till the certain exempt) :D
So now going to the end if I would have some support/guidance from the @vaxerski or any other contributor who could help me to review that (once finished) and to iterate on potential fixes if needed I am happy to continue working on that.
Thanks a lot for trying to implement that. I would also love to see full support for it. I am using kdeconnect which also requires this for mouse movement and keyboard presses. There is a MR in the xdg-desktop-portal-wlr project which also tries to implement that: https://github.com/emersion/xdg-desktop-portal-wlr/pull/263 Different ppl have progressed it bit by bit. I have actually been using this: https://github.com/Enovale/xdg-desktop-portal-wlr/commit/11817f90de8903a32b9ea0add3bb3a478c6635e5 on hyprland (in addition to xdg-desktop-portal-hyprland) for some months now. For me it works well enough and is certainly an upgrade compared to no remote control at all. All basic lower case letters are working as well as mouse movement. Maybe his implementation can help you with yours. He is also new to C so maybe you can help each other out :D
This is good progress. It should be possible to use libei directly or at least calling the upstream interfaces that are implemented now. I'm also taking a look at this and I'll submit a PR soon too.
portal.RemoteDesktop interface is not implemented, so we are lacking the ability to work with remote controlling Apps, like rust-desk.
Is there a plane to implement?