mirror of
https://github.com/eliasstepanik/imgui-rs.git
synced 2026-01-27 13:28:28 +00:00
Merge pull request #131 from malikolivier/imgui-add-mouse-wheel
[ImGui] Add helper function to get mouse wheel delta
This commit is contained in:
commit
37d556ce3b
@ -219,6 +219,11 @@ impl ImGui {
|
|||||||
let io = self.io_mut();
|
let io = self.io_mut();
|
||||||
io.mouse_wheel = value;
|
io.mouse_wheel = value;
|
||||||
}
|
}
|
||||||
|
/// Get mouse wheel delta
|
||||||
|
pub fn mouse_wheel(&self) -> f32 {
|
||||||
|
let io = self.io();
|
||||||
|
io.mouse_wheel
|
||||||
|
}
|
||||||
/// Set to `true` to have ImGui draw the cursor in software.
|
/// Set to `true` to have ImGui draw the cursor in software.
|
||||||
/// If `false`, the OS cursor is used (default to `false`).
|
/// If `false`, the OS cursor is used (default to `false`).
|
||||||
pub fn set_mouse_draw_cursor(&mut self, value: bool) {
|
pub fn set_mouse_draw_cursor(&mut self, value: bool) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user