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

Use alternative clipboard change monitor on macOS #348

Merged
merged 1 commit into from Feb 18, 2023

Conversation

shenlebantongying
Copy link
Collaborator

@shenlebantongying shenlebantongying commented Feb 18, 2023

On macOS, We have to monitor the clipboard change by reading the content every second.

Reason:

With Qt version 4.3 or higher, clipboard changes made by other applications will only be detected when the application is activated.

https://doc.qt.io/qt-6/qclipboard.html#dataChanged

Related: #219


The code is similar to https://github.com/KDE/kdeconnect-kde/blob/v22.12.2/plugins/clipboard/clipboardlistener.cpp#L48-L53

Demo:

Screen.Recording.2023-02-17.at.9.03.36.PM.mov

@shenlebantongying
Copy link
Collaborator Author

I think you can make a test pre-release after merging so that we can invite someone to test it.

Also, can you open the wiki editing to everyone so that we can have some specific documentation?

QClipboard cannot monitor data changes on mac unless an application is focused
@sonarcloud
Copy link

sonarcloud bot commented Feb 18, 2023

SonarCloud Quality Gate failed.    Quality Gate failed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

0.0% 0.0% Coverage
0.0% 0.0% Duplication

@xiaoyifang xiaoyifang merged commit a7c1589 into xiaoyifang:staged Feb 18, 2023
@xiaoyifang
Copy link
Owner

xiaoyifang commented Feb 19, 2023

@xiaoyifang
Copy link
Owner

Also, can you open the wiki editing to everyone so that we can have some specific documentation?

this feature can be easily abused. If someone want to commit to the wiki. he can make a PR ,and put the wiki content in the source folder such as wiki etc.

@shenlebantongying shenlebantongying added the macOS Like most cross-platform projects, this one also lacks macOS developers. Help wanted. label Jul 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
macOS Like most cross-platform projects, this one also lacks macOS developers. Help wanted.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants