aboutsummaryrefslogtreecommitdiff
path: root/libxcb/xcb-proto/xcbgen/xtypes.py
diff options
context:
space:
mode:
authormarha <marha@users.sourceforge.net>2013-07-16 08:59:33 +0200
committermarha <marha@users.sourceforge.net>2013-07-16 08:59:33 +0200
commitd00d82f6017166fdeb927320ce4c656cb99319fd (patch)
tree75d388ec743971c4bdcc85b639f8bc35458b27e0 /libxcb/xcb-proto/xcbgen/xtypes.py
parent707c146a74f6ff862be3ebb2470d1f31e29dd907 (diff)
parent06f4de23ace4de1fd628c37891214f0a4ecb77db (diff)
downloadvcxsrv-d00d82f6017166fdeb927320ce4c656cb99319fd.tar.gz
vcxsrv-d00d82f6017166fdeb927320ce4c656cb99319fd.tar.bz2
vcxsrv-d00d82f6017166fdeb927320ce4c656cb99319fd.zip
Merge remote-tracking branch 'origin/released'
* origin/released: libxcb xcb-proto mesa xkbcomp git update 16 Jul 2013 Conflicts: mesalib/src/glsl/glsl_symbol_table.cpp
Diffstat (limited to 'libxcb/xcb-proto/xcbgen/xtypes.py')
-rw-r--r--libxcb/xcb-proto/xcbgen/xtypes.py26
1 files changed, 21 insertions, 5 deletions
diff --git a/libxcb/xcb-proto/xcbgen/xtypes.py b/libxcb/xcb-proto/xcbgen/xtypes.py
index 5469cd961..a4614d9d2 100644
--- a/libxcb/xcb-proto/xcbgen/xtypes.py
+++ b/libxcb/xcb-proto/xcbgen/xtypes.py
@@ -602,25 +602,41 @@ class Event(ComplexType):
self.has_seq = not bool(elt.get('no-sequence-number'))
+ self.is_ge_event = bool(elt.get('xge'))
+
self.doc = None
for item in list(elt):
if item.tag == 'doc':
self.doc = Doc(name, item)
-
+
def add_opcode(self, opcode, name, main):
self.opcodes[name] = opcode
if main:
self.name = name
def resolve(self, module):
+ def add_event_header():
+ self.fields.append(Field(tcard8, tcard8.name, 'response_type', False, True, True))
+ if self.has_seq:
+ self.fields.append(_placeholder_byte)
+ self.fields.append(Field(tcard16, tcard16.name, 'sequence', False, True, True))
+
+ def add_ge_event_header():
+ self.fields.append(Field(tcard8, tcard8.name, 'response_type', False, True, True))
+ self.fields.append(Field(tcard8, tcard8.name, 'extension', False, True, True))
+ self.fields.append(Field(tcard16, tcard16.name, 'sequence', False, True, True))
+ self.fields.append(Field(tcard32, tcard32.name, 'length', False, True, True))
+ self.fields.append(Field(tcard16, tcard16.name, 'event_type', False, True, True))
+
if self.resolved:
return
# Add the automatic protocol fields
- self.fields.append(Field(tcard8, tcard8.name, 'response_type', False, True, True))
- if self.has_seq:
- self.fields.append(_placeholder_byte)
- self.fields.append(Field(tcard16, tcard16.name, 'sequence', False, True, True))
+ if self.is_ge_event:
+ add_ge_event_header()
+ else:
+ add_event_header()
+
ComplexType.resolve(self, module)
out = __main__.output['event']