Share the clipboard text between the session and the client

Only PortalSession forwards the local clipboard to the client right now. PlasmaScreencastV1Session's setClipboardData() is a no-op and it never listens for local clipboard changes at all, so Plasma sessions have no clipboard support. PortalSession also has a dead ignoreNextSystemClipboardChange field that was added but never wired up, so applying the client's clipboard locally can bounce straight back out as if it were a new local copy.

Moves the clipboard bridge onto AbstractSession so both session types share one implementation, extends it to Plasma sessions, and wires up the echo guard.

Also handles a client-capabilities-first ordering. mstsc doesn't send a format list when its own clipboard starts empty, so a pending server-side update would otherwise never get flushed on those clients.

Edited by Nick Haghiri

Merge request reports

Loading