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

Add options global clipboard clearing #225

Draft
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

alimirjamali
Copy link

Menu item to Global Clipboard widget to allow users to manually clear it.
Also global-clipboard-timeout feature could be set per VM and/or GUIVM

resolves: QubesOS/qubes-issues#6641

Menu item to Global Clipboard widget to allow users to manually clear it
Also `global-clipboard-timeout` feature could be set per VM and/or GUIVM

resolves: QubesOS/qubes-issues#6641
Copy link

codecov bot commented Oct 26, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.72%. Comparing base (bab3289) to head (74c435f).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #225      +/-   ##
==========================================
- Coverage   93.72%   93.72%   -0.01%     
==========================================
  Files          57       57              
  Lines       10845    10845              
==========================================
- Hits        10165    10164       -1     
- Misses        680      681       +1     
Flag Coverage Δ
?

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@marmarta
Copy link
Member

I like this, there is one problem: what if the widget crashes / someone is using a desktop environment that has problems with the widget, but the person relying on global clipboard will not know that the clearing stopped working (because copy-paste itself will work, just the notifications won't...). @marmarek mentioned that maybe this should happen in the gui daemon for that reason.

@alimirjamali
Copy link
Author

I like this, there is one problem: what if the widget crashes / someone is using a desktop environment that has problems with the widget, but the person relying on global clipboard will not know that the clearing stopped working (because copy-paste itself will work, just the notifications won't...). @marmarek mentioned that maybe this should happen in the gui daemon for that reason.

Well said. I believe the manual clearing in systray applet menu could still remain since it is useful.

The gui-daemon could signal timeout clearing via metadata like this:

successfull: 1
copy_action: 0
paste_action: 0
cleared: 1

The above should just generate a visual notification via widget.

And gui-daemon could check the existing metadata on timeout to assure global clipboard still belongs to that specific vm and that particular copy action. We just need another config/command line option for qubes-guid. I will work on it.

@alimirjamali alimirjamali marked this pull request as draft November 7, 2024 08:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Clear inter-VM global clipboard after a certain amount of time
2 participants