pub(crate) fn drag_source<P: Any + Send + Sync>(
ui: &mut Ui,
id: Id,
payload: P,
contents: impl FnOnce(&mut Ui),
) -> ResponseExpand description
An item that is clickable and right-clickable first and a drag-and-drop source second: the payload
is only handed to egui once drag_intent holds, and the body is lifted under the cursor from that
moment (the one thing Ui::dnd_drag_source is good for). Use this instead of dnd_drag_source,
which senses drag only — grab cursor on hover, and a drag on any press.