Merge pull request #27 from santigimeno/fix_event_type_parsing

Fix the parsing of the type field in Event msgs
This commit is contained in:
Andrey Sidorov 2013-05-10 04:47:10 -07:00
commit 97eade2c49

View file

@ -235,7 +235,9 @@ XClient.prototype.AllocID = function()
XClient.prototype.unpackEvent = function(type, seq, extra, code, raw)
{
var event = {}; // TODO: constructor & base functions
event.type = type;
// Remove the most significant bit. See Chapter 1, Event Format section in X11 protocol
// specification
event.type = type && 0x7F;
event.seq = seq;
var extUnpacker = this.eventParsers[type];