Checkpoint
This commit is contained in:
parent
da8919002f
commit
96f2c4a9de
8 changed files with 170 additions and 57 deletions
|
@ -1,5 +1,5 @@
|
|||
use crate::{
|
||||
px, size, Action, AnyBox, AnyView, AppContext, AsyncWindowContext, AvailableSpace,
|
||||
px, size, Action, AnyBox, AnyDrag, AnyView, AppContext, AsyncWindowContext, AvailableSpace,
|
||||
BorrowAppContext, Bounds, BoxShadow, Context, Corners, DevicePixels, DispatchContext,
|
||||
DisplayId, Edges, Effect, Element, EntityId, EventEmitter, FocusEvent, FontId, GlobalElementId,
|
||||
GlyphId, Handle, Hsla, ImageData, InputEvent, IsZero, KeyListener, KeyMatch, KeyMatcher,
|
||||
|
@ -1605,6 +1605,14 @@ impl<'a, 'w, V: Send + Sync + 'static> ViewContext<'a, 'w, V> {
|
|||
})
|
||||
});
|
||||
}
|
||||
|
||||
pub(crate) fn start_drag(&mut self, drag: AnyDrag) {
|
||||
self.app.active_drag = Some(drag);
|
||||
}
|
||||
|
||||
pub(crate) fn end_drag(&mut self) {
|
||||
self.app.active_drag = None;
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a, 'w, V: EventEmitter + Send + Sync + 'static> ViewContext<'a, 'w, V> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue