mirror of
https://gitlab.freedesktop.org/wlroots/wlr-protocols.git
synced 2026-05-06 04:28:25 +02:00
A typically clipboard manager works as follows: - On a new clipboard, we copy any text - If the clipboard becomes empty (typically because a client died), we paste our previously copied text Our race happens as follows: first copy: - client creates a wl_data_offer - compositors sees it forwards it clipboard manager which copies the text... second copy: - client deletes its old wl_data_offer before creating a new one - compositor forwards this update to clipboard manager - clipboard manager knows the clipboard is empty and starts its operation to prevent an empty clipboard - client creates a new wl_data_offer and calls set_selection - clipboard manager creates a new wlr_data_offer (with the old clipboard text) and calls set_selection The compositor can get these last two in any order, and we end up replacing our new clipboard content with out-of-date previous clipboard contents. This patch adds a serial number that can be used when a set_selection is used in repsonse to a selection event. |
||
|---|---|---|
| .. | ||
| wlr-data-control-unstable-v1.xml | ||
| wlr-export-dmabuf-unstable-v1.xml | ||
| wlr-foreign-toplevel-management-unstable-v1.xml | ||
| wlr-gamma-control-unstable-v1.xml | ||
| wlr-input-inhibitor-unstable-v1.xml | ||
| wlr-layer-shell-unstable-v1.xml | ||
| wlr-output-management-unstable-v1.xml | ||
| wlr-output-power-management-unstable-v1.xml | ||
| wlr-screencopy-unstable-v1.xml | ||
| wlr-virtual-pointer-unstable-v1.xml | ||