[−][src]Struct sdl2::mouse::MouseUtil
Mouse utility functions. Access with Sdl::mouse().
let sdl_context = sdl2::init().unwrap(); // Hide the cursor sdl_context.mouse().show_cursor(false);
Methods
impl MouseUtil[src]
pub fn focused_window_id(&self) -> Option<u32>[src]
Gets the id of the window which currently has mouse focus.
pub fn warp_mouse_in_window(&self, window: &Window, x: i32, y: i32)[src]
pub fn set_relative_mouse_mode(&self, on: bool)[src]
pub fn relative_mouse_mode(&self) -> bool[src]
pub fn is_cursor_showing(&self) -> bool[src]
pub fn show_cursor(&self, show: bool)[src]
pub fn capture(&self, enable: bool)[src]
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>, [src]
U: From<T>,
impl<T> From for T[src]
impl<T, U> TryFrom for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T> Borrow for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut for T where
T: ?Sized, [src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T[src]
impl<T, U> TryInto for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,