From 2cc4e17743eba1a327f70295d02a68bb6b73acec Mon Sep 17 00:00:00 2001 From: nickysn Date: Tue, 3 May 2016 00:03:27 +0000 Subject: [PATCH] + added boolean overloads for the functions in the xinput2 unit, that receive a TBool parameter git-svn-id: trunk@33626 - --- packages/x11/src/xinput2.pp | 46 +++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) diff --git a/packages/x11/src/xinput2.pp b/packages/x11/src/xinput2.pp index 7c3d3e55d3..86ee2a5076 100644 --- a/packages/x11/src/xinput2.pp +++ b/packages/x11/src/xinput2.pp @@ -500,6 +500,19 @@ function XIGrabDevice( mask: PXIEventMask ): TStatus; cdecl; external libXi; +{ boolean overload for the TBool parameter } +function XIGrabDevice( + dpy: PDisplay; + deviceid: cint; + grab_window: TWindow; + time: TTime; + cursor: TCursor; + grab_mode: cint; + paired_device_mode: cint; + owner_events: Boolean; + mask: PXIEventMask +): TStatus; inline; + function XIUngrabDevice( dpy: PDisplay; deviceid: cint; @@ -663,6 +676,22 @@ function XIGetProperty( data: PPcuchar ): TStatus; cdecl; external libXi; +{ boolean overload for the TBool parameter } +function XIGetProperty( + display: PDisplay; + deviceid: cint; + _property: TAtom; + offset: clong; + length: clong; + delete_property: Boolean; + _type: TAtom; + type_return: PAtom; + format_return: Pcint; + num_items_return: Pculong; + bytes_after_return: Pculong; + data: PPcuchar +): TStatus; inline; + procedure XIBarrierReleasePointers( display: PDisplay; barriers: PXIBarrierReleasePointerInfo; @@ -681,4 +710,21 @@ procedure XIFreeDeviceInfo(info: PXIDeviceInfo); cdecl; external libXi; //_XFUNCPROTOEND implementation + +function XIGrabDevice(dpy: PDisplay; deviceid: cint; grab_window: TWindow; + time: TTime; cursor: TCursor; grab_mode: cint; paired_device_mode: cint; + owner_events: Boolean; mask: PXIEventMask): TStatus; inline; +begin + XIGrabDevice(dpy, deviceid, grab_window, time, cursor, grab_mode, paired_device_mode, Ord(owner_events), mask); +end; + +function XIGetProperty(display: PDisplay; deviceid: cint; _property: TAtom; + offset: clong; length: clong; delete_property: Boolean; _type: TAtom; + type_return: PAtom; format_return: Pcint; num_items_return: Pculong; + bytes_after_return: Pculong; data: PPcuchar): TStatus; +begin + XIGetProperty(display, deviceid, _property, offset, length, Ord(delete_property), _type, type_return, format_return, + num_items_return, bytes_after_return, data); +end; + end.