{-# LANGUAGE ForeignFunctionInterface #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE NoFieldSelectors #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_HADDOCK prune #-}
module SDL3.Sys.Bindgen.System.Safe (
SDL3.Sys.Bindgen.System.Safe.sDL_SetX11EventHook,
SDL3.Sys.Bindgen.System.Safe.sDL_SetLinuxThreadPriority,
SDL3.Sys.Bindgen.System.Safe.sDL_SetLinuxThreadPriorityAndPolicy,
SDL3.Sys.Bindgen.System.Safe.sDL_IsTablet,
SDL3.Sys.Bindgen.System.Safe.sDL_IsTV,
SDL3.Sys.Bindgen.System.Safe.sDL_GetSandbox,
SDL3.Sys.Bindgen.System.Safe.sDL_OnApplicationWillTerminate,
SDL3.Sys.Bindgen.System.Safe.sDL_OnApplicationDidReceiveMemoryWarning,
SDL3.Sys.Bindgen.System.Safe.sDL_OnApplicationWillEnterBackground,
SDL3.Sys.Bindgen.System.Safe.sDL_OnApplicationDidEnterBackground,
SDL3.Sys.Bindgen.System.Safe.sDL_OnApplicationWillEnterForeground,
SDL3.Sys.Bindgen.System.Safe.sDL_OnApplicationDidEnterForeground,
)
where
import Prelude (IO, fmap)
import HsBindgen.Runtime.LibC qualified
import HsBindgen.Runtime.Support qualified as BG
import HsBindgen.Runtime.Support.CAPI qualified
import SDL3.Sys.Bindgen.Stdinc qualified
import SDL3.Sys.Bindgen.System
$( HsBindgen.Runtime.Support.CAPI.addCSource
( HsBindgen.Runtime.Support.CAPI.unlines
[ "#define SDL_MAIN_HANDLED"
, "#define SDL_SLOW_MEMCPY"
, "#define SDL_SLOW_MEMMOVE"
, "#define SDL_SLOW_MEMSET"
, "#include <SDL3/SDL_system.h>"
, "void hs_bindgen_ead2e2ea2677d0f8 ("
, " SDL_X11EventHook arg1,"
, " void *arg2"
, ")"
, "{"
, " (SDL_SetX11EventHook)(arg1, arg2);"
, "}"
, "_Bool hs_bindgen_9110686f4456a2f3 ("
, " Sint64 arg1,"
, " signed int arg2"
, ")"
, "{"
, "#ifdef SDL_PLATFORM_LINUX"
, " return (SDL_SetLinuxThreadPriority)(arg1, arg2);"
, "#else"
, " (void)arg1; (void)arg2; return SDL_SetError(\"SDL_SetLinuxThreadPriority is only available on Linux\");"
, "#endif"
, "}"
, "_Bool hs_bindgen_0383bd6da68658c0 ("
, " Sint64 arg1,"
, " signed int arg2,"
, " signed int arg3"
, ")"
, "{"
, "#ifdef SDL_PLATFORM_LINUX"
, " return (SDL_SetLinuxThreadPriorityAndPolicy)(arg1, arg2, arg3);"
, "#else"
, " (void)arg1; (void)arg2; (void)arg3; return SDL_SetError(\"SDL_SetLinuxThreadPriorityAndPolicy is only available on Linux\");"
, "#endif"
, "}"
, "_Bool hs_bindgen_c9f4754632fd8d42 (void)"
, "{"
, " return (SDL_IsTablet)();"
, "}"
, "_Bool hs_bindgen_0cd31739327b6cd7 (void)"
, "{"
, " return (SDL_IsTV)();"
, "}"
, "SDL_Sandbox hs_bindgen_e5a169479304c118 (void)"
, "{"
, " return (SDL_GetSandbox)();"
, "}"
, "void hs_bindgen_6de90d6f8ee04ad6 (void)"
, "{"
, " (SDL_OnApplicationWillTerminate)();"
, "}"
, "void hs_bindgen_36ae92858c8204df (void)"
, "{"
, " (SDL_OnApplicationDidReceiveMemoryWarning)();"
, "}"
, "void hs_bindgen_62c6019205cd45c2 (void)"
, "{"
, " (SDL_OnApplicationWillEnterBackground)();"
, "}"
, "void hs_bindgen_73b2cba299dd5591 (void)"
, "{"
, " (SDL_OnApplicationDidEnterBackground)();"
, "}"
, "void hs_bindgen_2b70d675ad267009 (void)"
, "{"
, " (SDL_OnApplicationWillEnterForeground)();"
, "}"
, "void hs_bindgen_cfd36268e651eb47 (void)"
, "{"
, " (SDL_OnApplicationDidEnterForeground)();"
, "}"
]
)
)
foreign import ccall safe "hs_bindgen_ead2e2ea2677d0f8"
hs_bindgen_ead2e2ea2677d0f8_base
:: BG.FunPtr BG.Void
-> BG.Ptr BG.Void
-> IO ()
hs_bindgen_ead2e2ea2677d0f8
:: SDL_X11EventHook
-> BG.Ptr BG.Void
-> IO ()
hs_bindgen_ead2e2ea2677d0f8 :: SDL_X11EventHook -> Ptr Void -> IO ()
hs_bindgen_ead2e2ea2677d0f8 =
\SDL_X11EventHook
x0 ->
\Ptr Void
x1 ->
FunPtr Void -> Ptr Void -> IO ()
hs_bindgen_ead2e2ea2677d0f8_base (SDL_X11EventHook -> FFIType SDL_X11EventHook
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_X11EventHook
x0) (Ptr Void -> FFIType (Ptr Void)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr Void
x1)
sDL_SetX11EventHook
:: SDL_X11EventHook
-> BG.Ptr BG.Void
-> IO ()
sDL_SetX11EventHook :: SDL_X11EventHook -> Ptr Void -> IO ()
sDL_SetX11EventHook = SDL_X11EventHook -> Ptr Void -> IO ()
hs_bindgen_ead2e2ea2677d0f8
foreign import ccall safe "hs_bindgen_9110686f4456a2f3"
hs_bindgen_9110686f4456a2f3_base
:: HsBindgen.Runtime.LibC.Int64
-> BG.CInt
-> IO BG.CBool
hs_bindgen_9110686f4456a2f3
:: SDL3.Sys.Bindgen.Stdinc.Sint64
-> BG.CInt
-> IO BG.CBool
hs_bindgen_9110686f4456a2f3 :: Sint64 -> CInt -> IO CBool
hs_bindgen_9110686f4456a2f3 =
\Sint64
x0 ->
\CInt
x1 ->
(CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Int64 -> CInt -> IO CBool
hs_bindgen_9110686f4456a2f3_base (Sint64 -> FFIType Sint64
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Sint64
x0) (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x1))
sDL_SetLinuxThreadPriority
:: SDL3.Sys.Bindgen.Stdinc.Sint64
-> BG.CInt
-> IO BG.CBool
sDL_SetLinuxThreadPriority :: Sint64 -> CInt -> IO CBool
sDL_SetLinuxThreadPriority =
Sint64 -> CInt -> IO CBool
hs_bindgen_9110686f4456a2f3
foreign import ccall safe "hs_bindgen_0383bd6da68658c0"
hs_bindgen_0383bd6da68658c0_base
:: HsBindgen.Runtime.LibC.Int64
-> BG.CInt
-> BG.CInt
-> IO BG.CBool
hs_bindgen_0383bd6da68658c0
:: SDL3.Sys.Bindgen.Stdinc.Sint64
-> BG.CInt
-> BG.CInt
-> IO BG.CBool
hs_bindgen_0383bd6da68658c0 :: Sint64 -> CInt -> CInt -> IO CBool
hs_bindgen_0383bd6da68658c0 =
\Sint64
x0 ->
\CInt
x1 ->
\CInt
x2 ->
(CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap
CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType
(Int64 -> CInt -> CInt -> IO CBool
hs_bindgen_0383bd6da68658c0_base (Sint64 -> FFIType Sint64
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Sint64
x0) (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x1) (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x2))
sDL_SetLinuxThreadPriorityAndPolicy
:: SDL3.Sys.Bindgen.Stdinc.Sint64
-> BG.CInt
-> BG.CInt
-> IO BG.CBool
sDL_SetLinuxThreadPriorityAndPolicy :: Sint64 -> CInt -> CInt -> IO CBool
sDL_SetLinuxThreadPriorityAndPolicy =
Sint64 -> CInt -> CInt -> IO CBool
hs_bindgen_0383bd6da68658c0
foreign import ccall safe "hs_bindgen_c9f4754632fd8d42"
hs_bindgen_c9f4754632fd8d42_base
:: IO BG.CBool
hs_bindgen_c9f4754632fd8d42 :: IO BG.CBool
hs_bindgen_c9f4754632fd8d42 :: IO CBool
hs_bindgen_c9f4754632fd8d42 =
(CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO CBool
hs_bindgen_c9f4754632fd8d42_base
sDL_IsTablet :: IO BG.CBool
sDL_IsTablet :: IO CBool
sDL_IsTablet = IO CBool
hs_bindgen_c9f4754632fd8d42
foreign import ccall safe "hs_bindgen_0cd31739327b6cd7"
hs_bindgen_0cd31739327b6cd7_base
:: IO BG.CBool
hs_bindgen_0cd31739327b6cd7 :: IO BG.CBool
hs_bindgen_0cd31739327b6cd7 :: IO CBool
hs_bindgen_0cd31739327b6cd7 =
(CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO CBool
hs_bindgen_0cd31739327b6cd7_base
sDL_IsTV :: IO BG.CBool
sDL_IsTV :: IO CBool
sDL_IsTV = IO CBool
hs_bindgen_0cd31739327b6cd7
foreign import ccall safe "hs_bindgen_e5a169479304c118"
hs_bindgen_e5a169479304c118_base
:: IO BG.CUInt
hs_bindgen_e5a169479304c118 :: IO SDL_Sandbox
hs_bindgen_e5a169479304c118 :: IO SDL_Sandbox
hs_bindgen_e5a169479304c118 =
(CUInt -> SDL_Sandbox) -> IO CUInt -> IO SDL_Sandbox
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CUInt -> SDL_Sandbox
FFIType SDL_Sandbox -> SDL_Sandbox
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO CUInt
hs_bindgen_e5a169479304c118_base
sDL_GetSandbox :: IO SDL_Sandbox
sDL_GetSandbox :: IO SDL_Sandbox
sDL_GetSandbox = IO SDL_Sandbox
hs_bindgen_e5a169479304c118
foreign import ccall safe "hs_bindgen_6de90d6f8ee04ad6"
hs_bindgen_6de90d6f8ee04ad6_base
:: IO ()
hs_bindgen_6de90d6f8ee04ad6 :: IO ()
hs_bindgen_6de90d6f8ee04ad6 :: IO ()
hs_bindgen_6de90d6f8ee04ad6 =
IO ()
hs_bindgen_6de90d6f8ee04ad6_base
sDL_OnApplicationWillTerminate :: IO ()
sDL_OnApplicationWillTerminate :: IO ()
sDL_OnApplicationWillTerminate =
IO ()
hs_bindgen_6de90d6f8ee04ad6
foreign import ccall safe "hs_bindgen_36ae92858c8204df"
hs_bindgen_36ae92858c8204df_base
:: IO ()
hs_bindgen_36ae92858c8204df :: IO ()
hs_bindgen_36ae92858c8204df :: IO ()
hs_bindgen_36ae92858c8204df =
IO ()
hs_bindgen_36ae92858c8204df_base
sDL_OnApplicationDidReceiveMemoryWarning :: IO ()
sDL_OnApplicationDidReceiveMemoryWarning :: IO ()
sDL_OnApplicationDidReceiveMemoryWarning =
IO ()
hs_bindgen_36ae92858c8204df
foreign import ccall safe "hs_bindgen_62c6019205cd45c2"
hs_bindgen_62c6019205cd45c2_base
:: IO ()
hs_bindgen_62c6019205cd45c2 :: IO ()
hs_bindgen_62c6019205cd45c2 :: IO ()
hs_bindgen_62c6019205cd45c2 =
IO ()
hs_bindgen_62c6019205cd45c2_base
sDL_OnApplicationWillEnterBackground :: IO ()
sDL_OnApplicationWillEnterBackground :: IO ()
sDL_OnApplicationWillEnterBackground =
IO ()
hs_bindgen_62c6019205cd45c2
foreign import ccall safe "hs_bindgen_73b2cba299dd5591"
hs_bindgen_73b2cba299dd5591_base
:: IO ()
hs_bindgen_73b2cba299dd5591 :: IO ()
hs_bindgen_73b2cba299dd5591 :: IO ()
hs_bindgen_73b2cba299dd5591 =
IO ()
hs_bindgen_73b2cba299dd5591_base
sDL_OnApplicationDidEnterBackground :: IO ()
sDL_OnApplicationDidEnterBackground :: IO ()
sDL_OnApplicationDidEnterBackground =
IO ()
hs_bindgen_73b2cba299dd5591
foreign import ccall safe "hs_bindgen_2b70d675ad267009"
hs_bindgen_2b70d675ad267009_base
:: IO ()
hs_bindgen_2b70d675ad267009 :: IO ()
hs_bindgen_2b70d675ad267009 :: IO ()
hs_bindgen_2b70d675ad267009 =
IO ()
hs_bindgen_2b70d675ad267009_base
sDL_OnApplicationWillEnterForeground :: IO ()
sDL_OnApplicationWillEnterForeground :: IO ()
sDL_OnApplicationWillEnterForeground =
IO ()
hs_bindgen_2b70d675ad267009
foreign import ccall safe "hs_bindgen_cfd36268e651eb47"
hs_bindgen_cfd36268e651eb47_base
:: IO ()
hs_bindgen_cfd36268e651eb47 :: IO ()
hs_bindgen_cfd36268e651eb47 :: IO ()
hs_bindgen_cfd36268e651eb47 =
IO ()
hs_bindgen_cfd36268e651eb47_base
sDL_OnApplicationDidEnterForeground :: IO ()
sDL_OnApplicationDidEnterForeground :: IO ()
sDL_OnApplicationDidEnterForeground =
IO ()
hs_bindgen_cfd36268e651eb47