shift + tab的关键代码是什么? [英] what is the key code for shift+tab?

查看:198
本文介绍了shift + tab的关键代码是什么?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在进行键映射。问题是,当我按Tab键时,它将导航到下一个输入字段。

I am working on key mapping. The problem is that when I press the TAB button down it navigates to the next input field.


TAB键为9, >
DOWN的键是40

TAB has key of 9 and
DOWN has key of 40

但是,什么是JavaScript键码转到前一个输入字段(SHIFT + TAB)?

But, what is the JavaScript key code to go to the previous input field (SHIFT + TAB)?

我想要的是去下一个链接;什么是以前的链接的键码或代码?

What I want is to go to next link; what is keycode or code for the previous link?

请帮忙。
由于

Please help. Thanks.

推荐答案

有没有 键码,这是一个事件对象的单独属性,如下所示:

There's no "keycode", it's a separate property on the event object, like this:

if(event.shiftKey && event.keyCode == 9) { 
  //shift was down when tab was pressed
}

这篇关于shift + tab的关键代码是什么?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆