pub struct DropTarget {
pub offset: usize,
pub row: usize,
}Expand description
Where a dragged block would land — the answer to Doc::drop_target_at.
A drop is aimed at a row (the one under the pointer) and lands at a
boundary (between two blocks), and a frontend needs both halves: the
offset to hand Doc::move_block, and the row to draw the indicator
above — which is not the row aimed at, since a drop on the lower half of a
block lands below it.
Fields§
§offset: usizeThe boundary offset — move_block’s to.
row: usizeThe rendered row the indicator is drawn above; rows.len() for a drop
below everything.
Trait Implementations§
Source§impl Clone for DropTarget
impl Clone for DropTarget
impl Copy for DropTarget
Source§impl Debug for DropTarget
impl Debug for DropTarget
impl Eq for DropTarget
Source§impl PartialEq for DropTarget
impl PartialEq for DropTarget
impl StructuralPartialEq for DropTarget
Auto Trait Implementations§
impl Freeze for DropTarget
impl RefUnwindSafe for DropTarget
impl Send for DropTarget
impl Sync for DropTarget
impl Unpin for DropTarget
impl UnsafeUnpin for DropTarget
impl UnwindSafe for DropTarget
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more