欧美bbbwbbbw肥妇,免费乱码人妻系列日韩,一级黄片

altKey 事件屬性

定義和用法

altKey 事件屬性返回一個布爾值。指示在指定的事件發(fā)生時,Alt 鍵是否被按下并保持住了。

語法

event.altKey=true|false|1|0

實例

下面的例子可提示當鼠標按鍵被點擊時 "ALT" 鍵是否已被按住:

<html>
<head>
<script type="text/javascript">
function isKeyPressed(event)
{
  if (event.altKey==1)
    {
    alert("The ALT key was pressed!")
    }
  else
    {
    alert("The ALT key was NOT pressed!")
    }
  }
</script>
</head>

<body onmousedown="isKeyPressed(event)">

<p>Click somewhere in the document.
An alert box will tell you if you 
pressed the ALT key or not.</p>

</body>
</html>

TIY

altKey
檢測 ALT 鍵是否已被按住。