Commit graph

1 commit

Author SHA1 Message Date
offline-ant
d19f99d1ef
selection: clipboard delegate, primary selection, mobile handles (#912)
* selection: clipboard delegate, primary selection, mobile UI, handles, accessibility

Level 0: Route clipboard through Makepad instead of arboard. Custom
ClipboardDelegate in havishell forwards set_text/get_text/clear through
Makepad's CopyToClipboard and pending paste state. Fix Wayland serial
constraint by queuing CopyToClipboard when no serial is available.

Level 1: Primary selection (Linux). Add CxOsOp::SetPrimarySelection,
Wayland zwp_primary_selection_device_manager_v1 protocol bindings, X11
PRIMARY atom handling. HAVI stores selection text in SharedDocumentSelection
and calls set_primary_selection on change.

Level 2: Mobile clipboard actions UI. Long-press selects word and shows
native clipboard toolbar. TextCopy/TextCut events return selection text.

Level 3: Selection handle API. Add CxOsOp Show/Update/HideSelectionHandles,
Event::SelectionHandleDrag, and HAVI integration for handle drag events.
Platform stubs for all backends.

Level 4: Accessibility plumbing. Add CxOsOp::AccessibilityUpdate with
type-erased Box<dyn Any + Send> payload. HAVI implements
notify_accessibility_tree_update to forward accesskit::TreeUpdate through
Makepad. Platform no-op stubs.

* wayland: handle primary selection data_offer child objects

---------

Co-authored-by: ant <ant@offline.click>
2026-03-06 12:17:25 +01:00