pub enum DropPosition {
Before(usize),
After(usize),
Inside(usize),
Replace(usize),
Append,
}Expand description
Where within a drop target the drop will occur.
Used by DropTarget::drop_position to communicate precise placement
to the drop handler.
Variants§
Before(usize)
Before the item at the given index.
After(usize)
After the item at the given index.
Inside(usize)
Inside the item at the given index (for tree-like targets).
Replace(usize)
Replace the item at the given index.
Append
Append to the end of the target’s items.
Implementations§
Source§impl DropPosition
impl DropPosition
Sourcepub fn is_insertion(&self) -> bool
pub fn is_insertion(&self) -> bool
Returns true if this is an insertion position (Before or After).
Trait Implementations§
Source§impl Clone for DropPosition
impl Clone for DropPosition
impl Copy for DropPosition
Source§impl Debug for DropPosition
impl Debug for DropPosition
impl Eq for DropPosition
Source§impl PartialEq for DropPosition
impl PartialEq for DropPosition
impl StructuralPartialEq for DropPosition
Auto Trait Implementations§
impl Forget for DropPosition
impl Freeze for DropPosition
impl Move for DropPosition
impl RefUnwindSafe for DropPosition
impl Send for DropPosition
impl Sync for DropPosition
impl Unpin for DropPosition
impl UnsafeUnpin for DropPosition
impl UnwindSafe for DropPosition
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