Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clipboard bugs #4409

Open
iDmple opened this issue Oct 31, 2024 · 1 comment
Open

Clipboard bugs #4409

iDmple opened this issue Oct 31, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@iDmple
Copy link
Contributor

iDmple commented Oct 31, 2024

Issue to track the server-side of Xpra-org/xpra-html5#326

  • when "clipboard direction is set to-server, Xpra-html5 internal copy paste does not work anymore" - which would be an xpra bug
  • the server sends clipboard data even when to-server is set - I believe this only happens for "greedy" clients (like MS Windows, MacOS and html5) - another xpra server bug
  • "when clipboard is enabled and clipboard direction is set to-server, Xpra-html5 internal copy paste does not work anymore" - another xpra server bug?

I'm running Xpra version 6.2.0-1 (.deb package) on Ubuntu 24.04 (k8s) and Xpra-html5 16.2 on Mac with Chrome Version 130.0.6723.59 (Official Build) (arm64).

@iDmple iDmple added the bug Something isn't working label Oct 31, 2024
@totaam
Copy link
Collaborator

totaam commented Nov 12, 2024

clipboard direction is set to-server, Xpra-html5 internal copy paste does not work anymore

Please provide more specific steps.
Running my server with --clipboard-direction=to-server, I can set the clipboard value in an xterm using:

$ echo foo | xclip -i -selection CLIPBOARD

And then read it from another xterm within the same session just fine:

$ xclip -o -selection CLIPBOARD
foo

I also tried with gedit, and again, no problems that I could see.

the server sends clipboard data even when to-server is set

Nope, I was wrong about this one.
I've just verified and with --clipboard-direction=to-server the clipboard data is not sent to the browser at all:

if self.owned or not self._can_send or xid == 0:
return

This check skips emitting clipboard tokens (_can_send is False for direction=to-server)
And this discards requests from clients:

xpra/xpra/clipboard/core.py

Lines 651 to 654 in 854231f

if not proxy._can_send:
log("request for %s but sending is disabled, sending 'none' back", name)
no_contents()
return

"when clipboard is enabled and clipboard direction is set to-server, Xpra-html5 internal copy paste does not work

How is this different from the first point?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants