--- title: window.onmouseup slug: Web/API/Window/onmouseup translation_of: Web/API/GlobalEventHandlers/onmouseup translation_of_original: Web/API/Window/onmouseup ---

{{ ApiRef() }}

概述

当前窗口的mouseup事件的事件句柄.

语法

window.onmouseup = funcRef;

参数

例子

window.onmouseup = doFunc;
<html>
<head>

<title>onmouseup测试</title>

<script type="text/javascript">

window.onmouseup = mouseup;

function mouseup()
{
 alert("检测到mouseup事件!");
}
</script>
</head>

<body>
<p>在页面上按下鼠标中某个键,保持几秒后松开.mouseup事件会在你松开鼠标时触发</p>
</body>
</html>

规范

没有任何公开的标准

{{ languages( { "ja": "ja/DOM/window.onmouseup" ,"en": "en/DOM/window.onmouseup" } ) }}