Fix vertical scroll being inverted on web targets (#1665)
This commit is contained in:
parent
89d4c06dec
commit
6ba583d198
3 changed files with 3 additions and 2 deletions
|
|
@ -31,7 +31,7 @@ pub fn mouse_position(event: &MouseEvent) -> LogicalPosition<f64> {
|
|||
|
||||
pub fn mouse_scroll_delta(event: &WheelEvent) -> Option<MouseScrollDelta> {
|
||||
let x = event.delta_x();
|
||||
let y = event.delta_y();
|
||||
let y = -event.delta_y();
|
||||
|
||||
match event.delta_mode() {
|
||||
WheelEvent::DOM_DELTA_LINE => Some(MouseScrollDelta::LineDelta(x as f32, y as f32)),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue