From 310fd066e91f454b990372ffa30e803cc8120975 Mon Sep 17 00:00:00 2001 From: Florian Merz Date: Thu, 11 Feb 2021 12:56:40 +0100 Subject: unslug zh-cn: move --- files/zh-cn/web/api/event.altkey/index.html | 44 ----------------------------- 1 file changed, 44 deletions(-) delete mode 100644 files/zh-cn/web/api/event.altkey/index.html (limited to 'files/zh-cn/web/api/event.altkey/index.html') diff --git a/files/zh-cn/web/api/event.altkey/index.html b/files/zh-cn/web/api/event.altkey/index.html deleted file mode 100644 index fb69717e99..0000000000 --- a/files/zh-cn/web/api/event.altkey/index.html +++ /dev/null @@ -1,44 +0,0 @@ ---- -title: event.altKey -slug: Web/API/event.altKey -translation_of: Web/API/MouseEvent/altKey -translation_of_original: Web/API/event.altKey ---- -

{{ ApiRef() }}

-

概述

-

表明当事件触发时,ALT键是否处于按下的状态.

-

语法

-
event.altKey
-
-

例子

-
var bool = event.altKey;
-
-

如果当事件触发时,ALT键处于按下的状态,则bool的值为true,否则为false.

-
<html>
-<head>
-<title>altKey 示例</title>
-
-<script type="text/javascript">
-
-function showChar(e){
-  alert(
-    "按下的键: " + String.fromCharCode(e.charCode) + "\n"
-    + "charCode: " + e.charCode + "\n"
-    + "是否按下ALT键: " + e.altKey + "\n"
-  );
-}
-
-</script>
-</head>
-
-<body onkeypress="showChar(event);">
-<p>
-按下一个字符键,尝试同时按下ALT键.<br />
-你也可以同时按下SHIFT键和ALT键.
-</p>
-</body>
-</html>
-
-

规范

-

DOM Level 2 Events - property of MouseEvent object

-

{{ languages( { "ja": "ja/DOM/event.altKey", "pl": "pl/DOM/event.altKey", "en": "en/DOM/event.altKey" } ) }}

-- cgit v1.2.3-54-g00ecf