Fix cursor position after a CursorLeft event
This commit is contained in:
parent
2ce5df0844
commit
72f89ba77f
2 changed files with 11 additions and 0 deletions
|
|
@ -40,6 +40,12 @@ pub fn window_event(
|
|||
y: position.y as f32,
|
||||
}))
|
||||
}
|
||||
WindowEvent::CursorEntered { .. } => {
|
||||
Some(Event::Mouse(mouse::Event::CursorEntered))
|
||||
}
|
||||
WindowEvent::CursorLeft { .. } => {
|
||||
Some(Event::Mouse(mouse::Event::CursorLeft))
|
||||
}
|
||||
WindowEvent::MouseInput { button, state, .. } => {
|
||||
let button = mouse_button(*button);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue