mousewheel
This commit is contained in:
12
src/main.rs
12
src/main.rs
@@ -83,6 +83,18 @@ impl Game for TestGame {
|
||||
}
|
||||
|
||||
self.input.on_mouse_event(state, button, modifiers);
|
||||
},
|
||||
Event::WindowEvent { event: WindowEvent::MouseWheel { device_id, delta, phase, modifiers }, .. } => {
|
||||
if self.log_config.input {
|
||||
let mods = mods_to_string(modifiers);
|
||||
if mods.len() > 0 {
|
||||
println!("Scroll {:?} {:?} {:?} + {:?}", device_id, phase, &mods, delta)
|
||||
} else {
|
||||
println!("Scroll {:?} {:?} {:?}", device_id, phase, delta)
|
||||
}
|
||||
}
|
||||
|
||||
self.input.on_mouse_wheel_event(&delta, &modifiers);
|
||||
}
|
||||
_ => {}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user