Christian Linhart
dc0c544fe0
schema: add switch-case
...
Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
2014-08-25 19:42:02 -04:00
Christian Linhart
754c737875
xinput: req ChangeDeviceProperty: bitcase to case
...
Change the bitcases to cases
and remove the comment which says that bitcases should converted to cases.
Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
2014-08-25 19:41:42 -04:00
Christian Linhart
127d34ac4f
xcbgen-parser: support switch-case
...
"case" is implemented as a variation of "bitcase" as follows:
The old class "BitCaseType" became the abstract class
"CaseOrBitcaseType" with two derived classes
"CaseType" and "BitcaseType".
(Therefore BitcaseType keeps the old semantic which may
be important for some generators)
There are two additional flags in class Type:
* is_case
* is_case_or_bitcase
The latter is for convenience because case and bitcase
have to be treated the same way in many cases.
The list of cases and bitcases in a SwitchType object
is still called "bitcases".
Reasons:
* Renaming that list would break generators based on the parser.
* Creating an extra list for cases would make other code more
complicated because you usually want to iterate over all
case and bitcase members of a switch.
Reviewed-by: Ran Benita <ran234@gmail.com>
2014-08-25 19:39:31 -04:00
Christian Linhart
4987a5c6bc
xml-xcb spec: describe switch-case
...
V2: patch revised according to suggestion from Peter Harris:
* add the restriction that <enumref>
inside <bitcase> can only refer to an enum's <bit> members, and
<enumref> inside <case> can only refer to an enum's <value> members.
Reviewed-by: Peter Harris <pharris@opentext.com>
Reviewed-by: Ran Benita <ran234@gmail.com>
2014-08-25 19:38:35 -04:00
Peter Harris
80a79d466d
Merge http://infra-srv1.demorecorder.com/git/free-sw/xcb/proto
...
See the mailing list for Reviewed-bys.
Thread root is
http://lists.freedesktop.org/archives/xcb/2014-August/009632.html
2014-08-25 19:34:30 -04:00
Ran Benita
88415e6399
Add "altmask" attribute, like "altenum" for masks
...
"altmask" means the field is principally a bitmask of bits from the
enum, but in some cases can obtain other values (e.g. "out-of-band" data
in a free bit).
Several fields in xinput will benefit from this extra metadata.
Suggested-by: Peter Harris <pharris@opentext.com>
Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: Peter Harris <pharris@opentext.com>
2014-08-25 19:28:59 -04:00
Christian Linhart
7d8c990d6a
xinput: add TODO list
...
Add TODO list of things which cannot be done yet
with the current feature-set of xml and the generator.
V2: Fix reference in the parametrized struct-paragraph:
to correctly refer to the GetDeviceMotionEvents-reply
(instead of the ChangeKeyboardDevice-request which
does not need parametrized structs.)
2014-08-25 13:42:56 +02:00
Christian Linhart
e238b3487e
xinput: replace initial pad of xinput1.x replies with field
...
Replace the initial 1-byte pad of Xinput-1.x replies
with CARD8-field "xi_reply_type", according to XIproto.h.
This may also help to implement assertions
based on the value of that field.
reference:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/getvers.c#n103
2014-08-25 13:42:56 +02:00
Christian Linhart
3e6ddac96f
xinput: rep SetDeviceMode.status: altenum to enum
...
Field "status" of the SetDeviceMode-reply
only allows values from enum GrabStatus.
Therefore it has an "enum" and not an "altenum".
Also: Add comment about valid values of field "status".
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n601
note:
The following spec also mentions value "3 + first_error":
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n891
This is probably an error in this old spec because:
* the X-Server code does not generate that value.
In case of error-codes, it does the following:
instead of sending the reply it returns
rep.status containing the error-code as returnvalue
of the function ProcXSetDeviceMode.
This will probably cause the sending of an XError.
code:
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/setmode.c#n86
* the new spec does not mention that value:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n601
2014-08-25 13:42:56 +02:00
Christian Linhart
36484e600c
xinput: struct XIDeviceInfo.name: cleanup of padding
...
Previuosly, the padding of list "name"
has been done by faking another list-length.
Correct this by using the real list-length,
and by adding a 4-byte align-pad after the list.
This yields the same total length of the struct,
and uses the correct length of the list "name".
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n768
code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XIQueryDevice.c#n92
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/xiquerydevice.c#n477
2014-08-25 13:42:56 +02:00
Christian Linhart
a2374e1039
xinput: req XIPassiveGrabDevice.time: field is unused
...
The request-field "time" is unused.
Add a comment about this.
V2: patch revised according to the following fix in the spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/commit/?id=81378a1e7139af9d476d90df8737c0c1a58670f3
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt?id=81378a1e7139af9d476d90df8737c0c1a58670f3#n1699
code:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h?id=inputproto-2.3.1#n680
2014-08-25 13:42:56 +02:00
Christian Linhart
41f364a809
xinput: ev BarrierHit.flags: add new mask
...
add new enum "BarrierFlags" as mask to field "flags"
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n2575
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2.h#n164
2014-08-25 13:42:56 +02:00
Christian Linhart
70b975cfd6
xinput: ev DeviceStateNotify.classes_reported: mask
...
add new enum "ClassesReportedMask" as mask to field "classes_reported"
V2: patch revised according to suggestion from Peter Harris:
* use names which indicate the way the bits should be flipped
V3: revised the diff-context according to the modification of patch 18/22 V2
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2401
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2220
2014-08-25 13:42:56 +02:00
Christian Linhart
df64e417b8
xinput: ev DeviceButtonStateNotify.device_id: mask
...
add mask "MoreEventsMask" to field "device_id"
V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
because all the legal values of device_id are not described
by the <bit> elements of MoreEventsMask.
V3: revised the diff-context according to the modification of patch 19/22 V2.
spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2252
http://cgit.freedesktop.org/xorg/xserver/tree/dix/enterleave.c#n725
note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2431
2014-08-25 13:42:56 +02:00
Christian Linhart
fe95c9448b
xinput: ev DeviceKeyStateNotify.device_id: mask
...
add mask "MoreEventsMask" to field "device_id"
V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
because all the legal values of device_id are not described
by the <bit> elements of MoreEventsMask.
spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2239
http://cgit.freedesktop.org/xorg/xserver/tree/dix/enterleave.c#n745
note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2428
2014-08-25 13:42:56 +02:00
Christian Linhart
01d0228f9b
xinput: ev DeviceStateNotify.device_id: mask
...
add mask "MoreEventsMask" to field "device_id"
V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
because all the legal values of device_id are not described
by the <bit> elements of MoreEventsMask.
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2214
http://cgit.freedesktop.org/xorg/xserver/tree/dix/enterleave.c#n725
note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2395
2014-08-25 13:42:56 +02:00
Christian Linhart
07e5a4a2f0
xinput: ev DeviceKeyPress.device_id: add mask
...
for event DeviceKeyPress and derived ones:
add new mask "MoreEventsMask" to field "device_id"
V2: patch revised according to suggestion from Peter Harris:
* use "altmask" instead of "mask"
because all the legal values of device_id are not described
by the <bit> elements of MoreEventsMask.
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1999
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XExtInt.c#n534
http://cgit.freedesktop.org/xorg/xserver/tree/dix/eventconvert.c#n348
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/exevents.c#n188
note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2257
2014-08-25 13:42:56 +02:00
Christian Linhart
f515871258
xinput: new enum for device_id in some events
...
add new enum "MoreEventsMask" to be used
by event DeviceKeyPress and derived ones
for field "device_id".
V2: patch revised according to suggestion from Peter Harris:
* remove DeviceBits = 0x7f from the enum in order to avoid
mixing bit and value in the same enum.
( We'd need a way to specify a range of bits for that ... )
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1999
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n67
http://cgit.freedesktop.org/xorg/lib/libXi/tree/src/XExtInt.c#n534
http://cgit.freedesktop.org/xorg/xserver/tree/dix/eventconvert.c#n348
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/exevents.c#n188
note:
this mask is missing in the following spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2257
2014-08-25 13:42:56 +02:00
Christian Linhart
b37ab52f96
xinput: ev ChangeDeviceNotify.request: add enum
...
add new enum "ChangeDevice" for field "request"
spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2301
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2459
2014-08-25 13:42:56 +02:00
Christian Linhart
cea46882b8
xinput: ev DeviceMappingNotify.request: add enum
...
add enum "Mapping" for field "request"
spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n2281
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2443
def of enum "Mapping":
http://cgit.freedesktop.org/xcb/proto/tree/src/xproto.xml#n1058
2014-08-25 13:42:56 +02:00
Christian Linhart
24cd3000e7
xinput: ev DeviceKeyPress.state: add mask
...
add mask KeyButMask to field "state"
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2271
2014-08-25 13:42:56 +02:00
Christian Linhart
319220781c
xinput: struct XIDeviceInfo.type: altenum to enum
...
field "type": replace altenum by enum because
only the values of DeviceType are permitted
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n669
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n763
notes to the spec:
* the field is called "use" in the spec, instead of "type"
* the enum is called "DEVICEUSE" in the spec, instead of "DeviceType"
2014-08-25 13:42:56 +02:00
Christian Linhart
7675fbdf29
xinput: struct ScrollClass.flags: has a mask
...
the field "flags" of struct ScrollClass uses ScrollFlags as a mask
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n802
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2.h#n151
2014-08-25 13:42:56 +02:00
Christian Linhart
27b22875e6
xinput: req ChangeFeedbackControl.mask: add mask
...
add new enum ChangeFeedbackControlMask to field "mask" as mask
V2: patch revised according to suggestion from Ran Benita:
* changed item name from "ledMode" to "LedMode" ( initial character uppercase )
to be consistent with the initial uppercase letter of the other items.
V2: added a note to the commit-message
about multiple items with the same value.
Note:
This enum contains multiple items with the same value.
This is defined that way in the spec.
The reason is probably as follows:
The semantic of those values probably depends on the
the value of field "class_id" of struct "FeedbackCtrl".
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1450
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n207
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/chgfctl.c
the following spec just mentions that the field "mask" is a BITMASK,
but does not list its values:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1725
2014-08-25 13:42:56 +02:00
Christian Linhart
dcd78ec389
xinput: struct ValuatorState.mode: add mask
...
add new enum ValuatorStateModeMask as mask to field "mode"
V2: patch revised according to suggestions from Peter Harris:
* use bit instead of value
* use names which indicate the way the bits should be flipped
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n2095
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1783
2014-08-25 13:42:56 +02:00
Christian Linhart
c272fb7b26
xinput: req UngrabDeviceButton.modifier_device: altenum
...
add altenum ModifierDevice to field modifier_device for value UseXKeyboard
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1225
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/ungrdevb.c#n111
the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1386
Questions:
* is this spec wrong?
* or does "NULL" have the unusual value of 0xff in this context?
2014-08-25 13:42:56 +02:00
Christian Linhart
280fff7458
xinput: req GrabDeviceButton.modifier_device: altenum
...
add altenum ModifierDevice to field modifier_device for value UseXKeyboard
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1195
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/grabdevb.c#n118
the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1309
Questions:
* is this spec wrong?
* or does "NULL" have the unusual value of 0xff in this context?
2014-08-25 13:42:56 +02:00
Christian Linhart
7b62d2b8f7
xinput: req UngrabDeviceKey.modifier_device: altenum
...
add altenum ModifierDevice to field modifier_device for value UseXKeyboard
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1175
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/ungrdevk.c#n113
the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1295
Questions:
* is this spec wrong?
* or does "NULL" have the unusual value of 0xff in this context?
2014-08-25 13:42:56 +02:00
Christian Linhart
20d642e7d1
xinput: req GrabDeviceKey.modifier_device: altenum
...
add altenum ModifierDevice to field modifier_device for value UseXKeyboard
V2: patch revised according to info from Ran Benita about NULL and UseXKeyboard
spec and code:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1147
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
http://cgit.freedesktop.org/xorg/xserver/tree/Xi/grabdevk.c#n116
the following spec uses "NULL" instead of "UseXKeyboard":
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1213
The reason for NULL vs UseXKeyboard is: in the libXi function XUngrabDeviceKey,
the modifier_device arg is an XDevice pointer, and NULL means to use the
core X keyboard. But on the wire it is an integer, with 255 as a special
value.
2014-08-25 13:42:55 +02:00
Christian Linhart
566ceb96d0
xinput: add new enum ModifierDevice
...
needed for field "modifier_device" in the following requests:
* GrabDeviceKey
* UngrabDeviceKey
* GrabDeviceButton
* UngrabDeviceButton
spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1147
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n187
2014-08-25 13:42:55 +02:00
Christian Linhart
8f5ae91616
xinput: rep ChangePointerDevice.status: altenum to enum
...
Field "status" can only get values from enum GrabStatus.
Therefore make it an enum instead of altenum.
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1055
Add comments:
Add comment about valid values for field "status".
Note:
An old spec lists value 2 for enum value "Frozen"
while enum GrabStatus has value 4 for Frozen.
The old spec is probably wrong.
Here is the URL of the old spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1073
2014-08-25 13:42:55 +02:00
Christian Linhart
aa8b37167c
xinput: rep ChangeKeyboardDevice.status: altenum to enum
...
Field "status" can only get values from enum GrabStatus
therefore make it an enum instead of altenum.
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1016
Add comment about valid values for field status.
Note:
An old spec lists value 2 for enum value "Frozen"
while enum GrabStatus has value 4 for Frozen.
The old spec is probably wrong.
Here is the URL of the old spec:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1044
2014-08-25 13:42:55 +02:00
Christian Linhart
63b08d46f6
xinput: enum InputClass: comment value Attach 7
...
The value Attach=7 is defined in XI.h but not supported anymore by libXi.
And it never was transmitted over the protocol.
(It was used to tag a fake class created by libXi)
Add this comment so that future reviews will not accidentally add this value.
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI.h#n242
drop of support in libXi:
http://cgit.freedesktop.org/xorg/lib/libXi/commit/?id=62858c426e6de1b99df660251737233afd335302
2014-08-25 13:42:55 +02:00
Christian Linhart
70d59f56b1
xinput: event Enter: fix type of fields same_screen and focus
...
fix type of fields "same_screen" and "focus" from CARD8 to BOOL
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n2432
(file-position in the above URL may become wrong if the spec changes)
2014-08-25 13:42:55 +02:00
Christian Linhart
e224ebbe20
xinput: request GrabDeviceButton: fix type of field owner_events
...
change type of field "owner_events" from CARD8 to BOOL
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n1311
(file-position in the above URL may become wrong if the spec changes)
2014-08-25 13:42:55 +02:00
Christian Linhart
d15b0f6113
xinput: struct AddMaster: fix type of fields
...
fix type of fields "send_core" and "enable" to BOOL
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n1187
note:
the type of these fields should also be fixed in XI2proto.h:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n460
(file-positions in the above URLs may become wrong if the spec changes)
2014-08-25 13:42:55 +02:00
Christian Linhart
506759adfd
xinput: reply XIQueryPointer: fix type of field same_screen
...
fix type of field "same_screen" from CARD8 to BOOL
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n1054
note:
the type of this field should also be fixed in XI2proto.h:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n386
(file-positions in the above URLs may become wrong if the spec or header changes)
2014-08-25 13:42:55 +02:00
Christian Linhart
9981b4e234
xinput: struct DeviceTimeCoord: replace CARD32 by INT32
...
replace CARD32 by INT32 in commented-out list "axisvalues"
spec:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XIproto.txt#n927
in this spec, the list is called "data" instead of "axisvalues"
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1018
in this spec, the list is called "valuators" instead of "axisvalues"
(file-positions in the above URLs may become wrong if the spec changes)
2014-08-25 13:42:55 +02:00
Christian Linhart
fcbd6d3e89
xinput: GetDeviceMotionEvents-request: add pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n992
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n474
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
5a24dadd9d
xinput: XIGetProperty-reply: add align-pad at end
...
reasons:
* all X11-replies must have a length which is a multiple of 4 bytes
* bitcases "8Bits" and "16bits" may have a length
which is not a multiple of 4 bytes
but they start on a 4-byte aligned position.
Therefore the unpadded end of the request may not be 4-byte aligned
* Therefore this requires a 4-byte align-pad.
notes:
* The align pad had to be added in each relevant bitcase
because adding it after the switch would cause the generator
to abort. (which is OK because a <switch> has to be the last item
of a struct, request or reply, according to the xcb-xml-spec)
2014-08-25 13:42:55 +02:00
Christian Linhart
d65d8836a0
xinput: struct AddMaster: add align-pad at end
...
reasons:
* length of the struct is a multiple of 4 according to spec.
* list of char may not end at a 4-byte aligned position.
see:
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/specs/XI2proto.txt#n1224
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n454
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XI2proto.h#n458
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
055c13096d
xinput: ChangeDeviceProperty-request: add align-pad at end
...
reasons:
* all X11-requests must have a length which is a multiple of 4 bytes
* bitcases "8Bits" and "16bits" may have a length
which is not a multiple of 4-bytes
but they start on a 4-byte aligned position.
Therefore the unpadded end of the request may not be 4-byte aligned
* Therefore this requires a 4-byte align-pad.
notes:
* The align pad had to be added in each relevant bitcase
because adding it after the switch would cause the generator
to abort. (which is OK because a <switch> has to be the last item
of a struct, request or reply, according to the xcb-xml-spec)
2014-08-25 13:42:55 +02:00
Christian Linhart
4f7ededf36
xinput: GetDeviceProperty-reply: add align-pad at end
...
reasons:
* all X11-replies must have a length which is a multiple of 4 bytes
* bitcases "8Bits" and "16bits" may have a length
which is not a multiple of 4-bytes
but they start on a 4-byte aligned position.
Therefore the unpadded end of the request may not be 4-byte aligned
* Therefore this requires a 4-byte align-pad.
notes:
* The align pad had to be added in each relevant bitcase
because adding it after the switch would cause the generator
to abort. (which is OK because a <switch> has to be the last item
of a struct, request or reply, according to the xcb-xml-spec)
2014-08-25 13:42:55 +02:00
Christian Linhart
13f1441673
xinput: GetDeviceButtonMapping-reply: add align-pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1691
(file-position may become wrong if the spec changes)
2014-08-25 13:42:55 +02:00
Christian Linhart
30b0406b1d
xinput: GetDeviceKeyMapping-request: add pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1583
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n982
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
aa18c4250a
xinput: SetDeviceFocus-request: add pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1308
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n737
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
c57d5cf58b
xinput: AllowDeviceEvents-request: add pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1251
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n692
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
a5c21eb0e5
xinput: UngrabDeviceButton-request: add pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1229
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n676
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
8da2ea01f3
xinput: UngrabDevice-request: add pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n1130
http://cgit.freedesktop.org/xorg/proto/inputproto/tree/XIproto.h#n596
(file-positions may become wrong if the spec or header change)
2014-08-25 13:42:55 +02:00
Christian Linhart
d9a3d5b1ab
xinput: OpenDevice-reply: add align-pad at end
...
see:
http://cgit.freedesktop.org/xorg/lib/libXi/tree/specs/encoding.xml#n834
(file-position may become wrong if the spec changes)
2014-08-25 13:42:55 +02:00