mirror of
https://github.com/zed-industries/zed.git
synced 2024-11-10 05:37:29 +03:00
Fix bug in drag move dispatch
co-authored-by: conrad <conrad@zed.dev>
This commit is contained in:
parent
139fe7c1f1
commit
4c63c74f92
@ -213,7 +213,7 @@ pub trait InteractiveElement: Sized {
|
||||
listener: impl Fn(&DragMoveEvent<T>, &mut WindowContext) + 'static,
|
||||
) -> Self
|
||||
where
|
||||
T: Render,
|
||||
T: 'static,
|
||||
{
|
||||
self.interactivity().mouse_move_listeners.push(Box::new(
|
||||
move |event, bounds, phase, cx| {
|
||||
@ -223,7 +223,7 @@ pub trait InteractiveElement: Sized {
|
||||
if cx
|
||||
.active_drag
|
||||
.as_ref()
|
||||
.is_some_and(|drag| drag.value.type_id() == TypeId::of::<T>())
|
||||
.is_some_and(|drag| (*drag.value).type_id() == TypeId::of::<T>())
|
||||
{
|
||||
(listener)(
|
||||
&DragMoveEvent {
|
||||
|
Loading…
Reference in New Issue
Block a user