Update virtual_event_from_websys_event based on make_synthetic_event in the desktop crate
This commit is contained in:
1 parent
60e74b2ec0
commit
f792ed7a17
1 file changed
+4
-4
@@ -178,7 +178,7 @@ fn virtual_event_from_websys_event(
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
"keydown" | "keypress" | "keyup" => Arc::new(KeyboardData::from(event)),
|
"keydown" | "keypress" | "keyup" => Arc::new(KeyboardData::from(event)),
|
||||||
"focus" | "blur" => Arc::new(FocusData {}),
|
"focus" | "blur" | "focusout" | "focusin" => Arc::new(FocusData {}),
|
||||||
|
|
||||||
// todo: these handlers might get really slow if the input box gets large and allocation pressure is heavy
|
// todo: these handlers might get really slow if the input box gets large and allocation pressure is heavy
|
||||||
// don't have a good solution with the serialized event problem
|
// don't have a good solution with the serialized event problem
|
||||||
@@ -258,9 +258,9 @@ fn virtual_event_from_websys_event(
|
|||||||
|
|
||||||
Arc::new(FormData { value, values })
|
Arc::new(FormData { value, values })
|
||||||
}
|
}
|
||||||
"click" | "contextmenu" | "doubleclick" | "drag" | "dragend" | "dragenter" | "dragexit"
|
"click" | "contextmenu" | "dblclick" | "doubleclick" | "drag" | "dragend" | "dragenter"
|
||||||
| "dragleave" | "dragover" | "dragstart" | "drop" | "mousedown" | "mouseenter"
|
| "dragexit" | "dragleave" | "dragover" | "dragstart" | "drop" | "mousedown"
|
||||||
| "mouseleave" | "mousemove" | "mouseout" | "mouseover" | "mouseup" => {
|
| "mouseenter" | "mouseleave" | "mousemove" | "mouseout" | "mouseover" | "mouseup" => {
|
||||||
Arc::new(MouseData::from(event))
|
Arc::new(MouseData::from(event))
|
||||||
}
|
}
|
||||||
"pointerdown" | "pointermove" | "pointerup" | "pointercancel" | "gotpointercapture"
|
"pointerdown" | "pointermove" | "pointerup" | "pointercancel" | "gotpointercapture"
|
||||||
|
|||||||
Reference in new issue
Block a user