Add DeviceEvent::MouseMove on web platform to support pointer lock (#1827)
* Add DeviceEvent::MouseMove on web platform to support pointer lock * Update changelog * Add support for stdweb too * Add mouse_delta to stdweb * Remove reference to pointer lock
This commit is contained in:
parent
b1be34c6a0
commit
7e0c6ee097
8 changed files with 33 additions and 6 deletions
|
|
@ -238,7 +238,7 @@ impl Canvas {
|
|||
|
||||
pub fn on_cursor_move<F>(&mut self, handler: F)
|
||||
where
|
||||
F: 'static + FnMut(i32, PhysicalPosition<f64>, ModifiersState),
|
||||
F: 'static + FnMut(i32, PhysicalPosition<f64>, PhysicalPosition<f64>, ModifiersState),
|
||||
{
|
||||
match &mut self.mouse_state {
|
||||
MouseState::HasPointerEvent(h) => h.on_cursor_move(&self.common, handler),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue