Clear last-mouse-moved pressed button when that button gets a mouse-up
This fixes an annoying issue where if the last mouse moved event was during a drag it would never trigger mouse cursor changes until next mouse move reset it. It makes sense to continue to not change the cursor while the button is pressed so instead this tracks when the mouse button is released in order to update the mouse move event
This commit is contained in:
parent
b61e9a940e
commit
b8b951deab
2 changed files with 54 additions and 44 deletions
|
@ -64,7 +64,7 @@ impl Default for MouseButton {
|
|||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug, Default)]
|
||||
#[derive(Clone, Copy, Debug, Default)]
|
||||
pub struct MouseButtonEvent {
|
||||
pub button: MouseButton,
|
||||
pub position: Vector2F,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue