document.onkeydown = function(e){ switch (e.which){
case 37:
console.log('键盘左方向');
break;
case 39:
console.log('键盘右方向');
break;
}
}
document.onkeydown = function(e){ switch (e.which){
case 37:
console.log('键盘左方向');
break;
case 39:
console.log('键盘右方向');
break;
}
}
评论 (0)