Added a timestamp to track clipboard changes, so when a new device connects it will sync the most recently updated clipboard to both devices.
Details
Details
- Reviewers
albertvaka - Group Reviewers
KDE Connect - Commits
- R224:779997337179: Clipboard sync on new connection
Diff Detail
Diff Detail
- Repository
- R224 KDE Connect
- Branch
- clipboardNewConnectionSync
- Lint
Lint OK - Unit
No Unit Test Coverage - Build Status
Buildable 14214 Build 14232: arc lint + arc unit
plugins/clipboard/clipboardlistener.h | ||
---|---|---|
40 ↗ | (On Diff #62128) | Typically local variables are prefixed with m_<varname>, so like m_updateTimestamp. Of course, this should apply to currentContent as well... |
61–62 ↗ | (On Diff #62128) | Usually getters are just named <varname>, so like qint64 updateTimestamp() |
plugins/clipboard/clipboardplugin.cpp | ||
57 ↗ | (On Diff #62128) | Space before { |
72 ↗ | (On Diff #62128) | } else { (Spaces) |
plugins/clipboard/clipboardplugin.cpp | ||
---|---|---|
61 ↗ | (On Diff #62128) | This can be simplified with the other if branch. |
plugins/clipboard/clipboardplugin.cpp | ||
---|---|---|
40 ↗ | (On Diff #62128) | As discussed, use a new packet type so this doesn't affect old apps. Also on Android. |