module Bindings.WLC.Wayland where
import Foreign.Ptr (Ptr,FunPtr,plusPtr)
import Foreign.Ptr (wordPtrToPtr,castPtrToFunPtr)
import Foreign.Storable
import Foreign.C.Types
import Foreign.C.String (CString,CStringLen,CWString,CWStringLen)
import Foreign.Marshal.Alloc (alloca)
import Foreign.Marshal.Array (peekArray,pokeArray)
import Data.Int
import Data.Word
import Bindings.WLC.Defines
import Bindings.WLC.Geometry
type C'wlc_resource = CUIntPtr
data C'wl_resource = C'wl_resource
data C'wl_display = C'wl_display
data C'wl_client = C'wl_client
data C'wl_interface = C'wl_interface
foreign import ccall "wlc_get_wl_display" c'wlc_get_wl_display
:: IO (Ptr C'wl_display)
foreign import ccall "&wlc_get_wl_display" p'wlc_get_wl_display
:: FunPtr (IO (Ptr C'wl_display))
foreign import ccall "wlc_handle_from_wl_surface_resource" c'wlc_handle_from_wl_surface_resource
:: Ptr C'wl_resource -> IO C'wlc_handle
foreign import ccall "&wlc_handle_from_wl_surface_resource" p'wlc_handle_from_wl_surface_resource
:: FunPtr (Ptr C'wl_resource -> IO C'wlc_handle)
foreign import ccall "wlc_handle_from_wl_output_resource" c'wlc_handle_from_wl_output_resource
:: Ptr C'wl_resource -> IO C'wlc_handle
foreign import ccall "&wlc_handle_from_wl_output_resource" p'wlc_handle_from_wl_output_resource
:: FunPtr (Ptr C'wl_resource -> IO C'wlc_handle)
foreign import ccall "wlc_resource_from_wl_surface_resource" c'wlc_resource_from_wl_surface_resource
:: Ptr C'wl_resource -> IO C'wlc_resource
foreign import ccall "&wlc_resource_from_wl_surface_resource" p'wlc_resource_from_wl_surface_resource
:: FunPtr (Ptr C'wl_resource -> IO C'wlc_resource)
foreign import ccall "wlc_surface_get_size" c'wlc_surface_get_size
:: C'wlc_resource -> IO (Ptr C'wlc_size)
foreign import ccall "&wlc_surface_get_size" p'wlc_surface_get_size
:: FunPtr (C'wlc_resource -> IO (Ptr C'wlc_size))
foreign import ccall "wlc_surface_get_wl_resource" c'wlc_surface_get_wl_resource
:: C'wlc_resource -> IO (Ptr C'wl_resource)
foreign import ccall "&wlc_surface_get_wl_resource" p'wlc_surface_get_wl_resource
:: FunPtr (C'wlc_resource -> IO (Ptr C'wl_resource))
foreign import ccall "wlc_view_from_surface" c'wlc_view_from_surface
:: C'wlc_resource -> Ptr C'wl_client -> Ptr C'wl_interface -> Ptr () -> CUInt -> CUInt -> Ptr () -> IO C'wlc_handle
foreign import ccall "&wlc_view_from_surface" p'wlc_view_from_surface
:: FunPtr (C'wlc_resource -> Ptr C'wl_client -> Ptr C'wl_interface -> Ptr () -> CUInt -> CUInt -> Ptr () -> IO C'wlc_handle)
foreign import ccall "wlc_view_get_surface" c'wlc_view_get_surface
:: C'wlc_handle -> IO C'wlc_resource
foreign import ccall "&wlc_view_get_surface" p'wlc_view_get_surface
:: FunPtr (C'wlc_handle -> IO C'wlc_resource)
foreign import ccall "wlc_surface_get_subsurfaces" c'wlc_surface_get_subsurfaces
:: C'wlc_resource -> Ptr CSize -> IO (Ptr C'wlc_resource)
foreign import ccall "&wlc_surface_get_subsurfaces" p'wlc_surface_get_subsurfaces
:: FunPtr (C'wlc_resource -> Ptr CSize -> IO (Ptr C'wlc_resource))
foreign import ccall "wlc_get_subsurface_geometry" c'wlc_get_subsurface_geometry
:: C'wlc_resource -> Ptr C'wlc_geometry -> IO ()
foreign import ccall "&wlc_get_subsurface_geometry" p'wlc_get_subsurface_geometry
:: FunPtr (C'wlc_resource -> Ptr C'wlc_geometry -> IO ())
foreign import ccall "wlc_view_get_wl_client" c'wlc_view_get_wl_client
:: C'wlc_handle -> IO (Ptr C'wl_client)
foreign import ccall "&wlc_view_get_wl_client" p'wlc_view_get_wl_client
:: FunPtr (C'wlc_handle -> IO (Ptr C'wl_client))
foreign import ccall "wlc_view_get_role" c'wlc_view_get_role
:: C'wlc_handle -> IO (Ptr C'wl_resource)
foreign import ccall "&wlc_view_get_role" p'wlc_view_get_role
:: FunPtr (C'wlc_handle -> IO (Ptr C'wl_resource))