Am 2018-08-01 17:43, schrieb Aleix Pol:
Hey, One of the most useful features in KDE Connect is the clipboard integration, this is not working currently. I'm guessing it's a privileges issue, I was wondering if it would maybe be possible to fix it by doing something like we're doing for fake input:
the reason why it's not working is the same for why klipper is not working: clipboard is not a shared medium anymore, but the compositor grants applications to write to the clipboard and to read from the clipboard. Both is strictly tied to having (keyboard) focus.
For kdeconnect this means it's not possible to write to the clipboard nor to read from the clipboard as it doesn't have a gui which could gain focus (obviously having a gui would not really be a solution here).
The ideas I had was to have a kind of clipboard manager which is always informed when clipboard content changes and is also allowed to write clipboard. I had a draft protocol, but I never got it to work properly for the klipper case as it tried to sync into both directions. But for the kdeconnect case the approach could work. Basically what we need is a protocol which allows to always set the data source and to get data offers. This would probably make sense to have in wayland-protocols as it's a rather generic problem (e.g. also virtual machines need this feature).
Cheers Martin