I took a key codes list on internet and I noticed that it's may not be completely exact (at least on my mac). If you have information about that please contact me
I'll maybe add a key aliases array to have multiple name for a same key (ex: left window key = left cmd key = left win = left cmd).
Conflict with OS/browser shortcuts (don't know if it's really an issue but I prefer to notice it here.)
Demonstrations
Single key
var dest = parseInt($('#demo div').css('left'));
$().shortcut('left arrow', function() {
dest = dest - 10 < 0 ? 0 : dest - 10;
$('#demo div').stop(true, false).animate({
left: dest + '%'
});
$('#demo div div').text('←');
}, function() {
$('#demo div div').text('');
});
$().shortcut('right arrow', function() {
dest = dest + 10 > 100 ? 100 : dest + 10;
$('#demo div').stop(true, false).animate({
left: dest + '%'
});
$('#demo div div').text('→');
}, function() {
$('#demo div div').text('');
});