pub use crate::{error::*, stdinc::*, video::*};
#[repr(transparent)]
pub struct SDL_Cursor(c_void);
#[derive(Debug, Clone, Copy, Default, PartialEq, Eq, PartialOrd, Ord, Hash)]
#[repr(transparent)]
pub struct SDL_SystemCursor(pub i32);
pub const SDL_SYSTEM_CURSOR_ARROW: SDL_SystemCursor = SDL_SystemCursor(0);
pub const SDL_SYSTEM_CURSOR_IBEAM: SDL_SystemCursor = SDL_SystemCursor(1);
pub const SDL_SYSTEM_CURSOR_WAIT: SDL_SystemCursor = SDL_SystemCursor(2);
pub const SDL_SYSTEM_CURSOR_CROSSHAIR: SDL_SystemCursor = SDL_SystemCursor(3);
pub const SDL_SYSTEM_CURSOR_WAITARROW: SDL_SystemCursor = SDL_SystemCursor(4);
pub const SDL_SYSTEM_CURSOR_SIZENWSE: SDL_SystemCursor = SDL_SystemCursor(5);
pub const SDL_SYSTEM_CURSOR_SIZENESW: SDL_SystemCursor = SDL_SystemCursor(6);
pub const SDL_SYSTEM_CURSOR_SIZEWE: SDL_SystemCursor = SDL_SystemCursor(7);
pub const SDL_SYSTEM_CURSOR_SIZENS: SDL_SystemCursor = SDL_SystemCursor(8);
pub const SDL_SYSTEM_CURSOR_SIZEALL: SDL_SystemCursor = SDL_SystemCursor(9);
pub const SDL_SYSTEM_CURSOR_NO: SDL_SystemCursor = SDL_SystemCursor(10);
pub const SDL_SYSTEM_CURSOR_HAND: SDL_SystemCursor = SDL_SystemCursor(11);
pub const SDL_NUM_SYSTEM_CURSORS: usize = 12;
#[derive(Debug, Clone, Copy, Default, PartialEq, Eq, PartialOrd, Ord, Hash)]
#[repr(transparent)]
pub struct SDL_MouseWheelDirection(pub i32);
pub const SDL_MOUSEWHEEL_NORMAL: SDL_MouseWheelDirection =
SDL_MouseWheelDirection(0);
pub const SDL_MOUSEWHEEL_FLIPPED: SDL_MouseWheelDirection =
SDL_MouseWheelDirection(1);
extern "C" {
pub fn SDL_GetMouseFocus() -> *mut SDL_Window;
pub fn SDL_GetMouseState(x: *mut c_int, y: *mut c_int) -> u32;
pub fn SDL_GetGlobalMouseState(x: *mut c_int, y: *mut c_int) -> u32;
pub fn SDL_GetRelativeMouseState(x: *mut c_int, y: *mut c_int) -> u32;
pub fn SDL_WarpMouseInWindow(window: *mut SDL_Window, x: c_int, y: c_int);
pub fn SDL_WarpMouseGlobal(x: c_int, y: c_int) -> c_int;
pub fn SDL_SetRelativeMouseMode(enabled: SDL_bool) -> c_int;
pub fn SDL_CaptureMouse(enabled: SDL_bool) -> c_int;
pub fn SDL_GetRelativeMouseMode() -> SDL_bool;
pub fn SDL_CreateCursor(
data: *const Uint8, mask: *const Uint8, w: c_int, h: c_int, hot_x: c_int,
hot_y: c_int,
) -> *mut SDL_Cursor;
pub fn SDL_CreateColorCursor(
surface: *mut SDL_Surface, hot_x: c_int, hot_y: c_int,
) -> *mut SDL_Cursor;
pub fn SDL_CreateSystemCursor(id: SDL_SystemCursor) -> *mut SDL_Cursor;
pub fn SDL_SetCursor(cursor: *mut SDL_Cursor);
pub fn SDL_GetCursor() -> *mut SDL_Cursor;
pub fn SDL_GetDefaultCursor() -> *mut SDL_Cursor;
pub fn SDL_FreeCursor(cursor: *mut SDL_Cursor);
pub fn SDL_ShowCursor(toggle: c_int) -> c_int;
}
pub const fn SDL_BUTTON(x: u32) -> u32 {
1 << (x - 1)
}
pub const SDL_BUTTON_LEFT: u32 = 1;
pub const SDL_BUTTON_MIDDLE: u32 = 2;
pub const SDL_BUTTON_RIGHT: u32 = 3;
pub const SDL_BUTTON_X1: u32 = 4;
pub const SDL_BUTTON_X2: u32 = 5;
pub const SDL_BUTTON_LMASK: u32 = SDL_BUTTON(SDL_BUTTON_LEFT);
pub const SDL_BUTTON_MMASK: u32 = SDL_BUTTON(SDL_BUTTON_MIDDLE);
pub const SDL_BUTTON_RMASK: u32 = SDL_BUTTON(SDL_BUTTON_RIGHT);
pub const SDL_BUTTON_X1MASK: u32 = SDL_BUTTON(SDL_BUTTON_X1);
pub const SDL_BUTTON_X2MASK: u32 = SDL_BUTTON(SDL_BUTTON_X2);