mirror of
https://github.com/Ryujinx/SDL2-CS.git
synced 2025-03-04 18:39:39 +00:00
Overloads for GetMouseState
This commit is contained in:
parent
df0b8c03d6
commit
818830fc3a
16
src/SDL2.cs
16
src/SDL2.cs
|
@ -4375,10 +4375,24 @@ namespace SDL2
|
|||
public static extern IntPtr SDL_GetMouseFocus();
|
||||
|
||||
/* Get the current state of the mouse */
|
||||
/* NOTE: Not sure if x,y should be 'ref', as SDL accepts null */
|
||||
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
|
||||
public static extern UInt32 SDL_GetMouseState(out int x, out int y);
|
||||
|
||||
/* Get the current state of the mouse */
|
||||
/* This overload allows for passing NULL to x */
|
||||
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
|
||||
public static extern UInt32 SDL_GetMouseState(IntPtr x, out int y);
|
||||
|
||||
/* Get the current state of the mouse */
|
||||
/* This overload allows for passing NULL to y */
|
||||
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
|
||||
public static extern UInt32 SDL_GetMouseState(out int x, IntPtr y);
|
||||
|
||||
/* Get the current state of the mouse */
|
||||
/* This overload allows for passing NULL to both x and y */
|
||||
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
|
||||
public static extern UInt32 SDL_GetMouseState(IntPtr x, IntPtr y);
|
||||
|
||||
/* Get the mouse state with relative coords*/
|
||||
[DllImport(nativeLibName, CallingConvention = CallingConvention.Cdecl)]
|
||||
public static extern UInt32 SDL_GetRelativeMouseState(out int x, out int y);
|
||||
|
|
Loading…
Reference in a new issue