require key to be released before continuing in getKeyboardResponse

This commit is contained in:
Josh de Leeuw 2014-06-30 09:33:12 -04:00
parent 3c70abc3aa
commit 94446016ae

View File

@ -673,10 +673,19 @@
core.cancelKeyboardResponse(listener_id);
}
callback_function({
key: e.which,
rt: key_time - start_time
});
var after_up = function(up) {
if(up.which == e.which) {
$(document).unbind('keyup', after_up);
callback_function({
key: e.which,
rt: key_time - start_time
});
}
}
$(document).keyup(after_up);
}
};