зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1465425 [wpt PR 9813] - Update the pointerlock IDL file, a=testonly
Automatic update from web-platform-testsUpdate the pointerlock IDL file (#9813) -- wpt-commits: 9fea339a9bde3bfbb0b880e236eaf4ce7487168d wpt-pr: 9813
This commit is contained in:
Родитель
a4fcda6120
Коммит
f0e6e64b56
|
@ -287204,6 +287204,11 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"interfaces/pointerlock.idl": [
|
||||
[
|
||||
{}
|
||||
]
|
||||
],
|
||||
"interfaces/proximity.idl": [
|
||||
[
|
||||
{}
|
||||
|
@ -356046,9 +356051,9 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"pointerlock/idlharness.html": [
|
||||
"pointerlock/interfaces.window.js": [
|
||||
[
|
||||
"/pointerlock/idlharness.html",
|
||||
"/pointerlock/interfaces.window.html",
|
||||
{}
|
||||
]
|
||||
],
|
||||
|
@ -580957,6 +580962,10 @@
|
|||
"29ca4e05813256592af7e9804e8135aaffdcc995",
|
||||
"support"
|
||||
],
|
||||
"interfaces/pointerlock.idl": [
|
||||
"6d3ff2b3f8b4015f3cb282db2cd2dbb8c2e90db5",
|
||||
"support"
|
||||
],
|
||||
"interfaces/proximity.idl": [
|
||||
"74f2bf81a497589e7b3ed323368df218a70925a3",
|
||||
"support"
|
||||
|
@ -591557,8 +591566,8 @@
|
|||
"6b77dd2bd357f9e902846b9f96059537dda35b3e",
|
||||
"testharness"
|
||||
],
|
||||
"pointerlock/idlharness.html": [
|
||||
"0d822320837b64c480e32e5110cf0f00adaf570c",
|
||||
"pointerlock/interfaces.window.js": [
|
||||
"597ed15f67c4f94f15b28b167fe7ac0ce1b7d79c",
|
||||
"testharness"
|
||||
],
|
||||
"pointerlock/movementX_Y_basic-manual.html": [
|
||||
|
|
|
@ -0,0 +1,27 @@
|
|||
// GENERATED CONTENT - DO NOT EDIT
|
||||
// Content of this file was automatically extracted from the Pointer Lock spec.
|
||||
// See https://w3c.github.io/pointerlock/
|
||||
|
||||
partial interface Element {
|
||||
void requestPointerLock();
|
||||
};
|
||||
|
||||
partial interface Document {
|
||||
attribute EventHandler onpointerlockchange;
|
||||
attribute EventHandler onpointerlockerror;
|
||||
void exitPointerLock();
|
||||
};
|
||||
|
||||
partial interface DocumentOrShadowRoot {
|
||||
readonly attribute Element ? pointerLockElement;
|
||||
};
|
||||
|
||||
partial interface MouseEvent {
|
||||
readonly attribute long movementX;
|
||||
readonly attribute long movementY;
|
||||
};
|
||||
|
||||
partial dictionary MouseEventInit {
|
||||
long movementX = 0;
|
||||
long movementY = 0;
|
||||
};
|
|
@ -1,70 +0,0 @@
|
|||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<title>Pointer Lock IDL tests</title>
|
||||
<link rel="author" title="W3C" href="http://www.w3.org/" />
|
||||
<link rel="help" href="http://www.w3.org/TR/pointerlock/#element-interface"/>
|
||||
<link rel="help" href="http://www.w3.org/TR/pointerlock/#extensions-to-the-document-interface">
|
||||
<link rel="help" href="http://www.w3.org/TR/pointerlock/#extensions-to-the-mouseevent-interface">
|
||||
<script src="/resources/testharness.js"></script>
|
||||
<script src="/resources/testharnessreport.js"></script>
|
||||
<script src="/resources/WebIDLParser.js"></script>
|
||||
<script src="/resources/idlharness.js"></script>
|
||||
</head>
|
||||
|
||||
<body>
|
||||
<h1>Pointer Lock IDL tests</h1>
|
||||
|
||||
<pre id='idl'>
|
||||
partial interface Element {
|
||||
void requestPointerLock ();
|
||||
};
|
||||
|
||||
partial interface Document {
|
||||
attribute EventHandler onpointerlockchange;
|
||||
attribute EventHandler onpointerlockerror;
|
||||
readonly attribute Element? pointerLockElement;
|
||||
void exitPointerLock ();
|
||||
};
|
||||
|
||||
partial interface MouseEvent {
|
||||
readonly attribute long movementX;
|
||||
readonly attribute long movementY;
|
||||
};
|
||||
|
||||
partial dictionary MouseEventInit {
|
||||
long movementX = 0;
|
||||
long movementY = 0;
|
||||
};
|
||||
</pre>
|
||||
|
||||
<div id="log"></div>
|
||||
|
||||
<script>
|
||||
"use strict";
|
||||
|
||||
promise_test(async () => {
|
||||
const idl_array = new IdlArray();
|
||||
const uievents = await fetch('/interfaces/uievents.idl').then(r => r.text());
|
||||
const dom = await fetch('/interfaces/dom.idl').then(r => r.text());
|
||||
const html = await fetch('/interfaces/html.idl').then(r => r.text());
|
||||
|
||||
idl_array.add_idls(document.getElementById("idl").textContent);
|
||||
idl_array.add_dependency_idls(uievents);
|
||||
idl_array.add_dependency_idls(dom);
|
||||
idl_array.add_dependency_idls(html);
|
||||
|
||||
idl_array.add_objects({
|
||||
Document: ["window.document"],
|
||||
Element: ["window.document.documentElement"],
|
||||
MouseEvent: [
|
||||
"new MouseEvent('mousemove')",
|
||||
"new MouseEvent('pointerlockchange')"
|
||||
],
|
||||
});
|
||||
idl_array.test();
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
|
@ -0,0 +1,26 @@
|
|||
// META: script=/resources/WebIDLParser.js
|
||||
// META: script=/resources/idlharness.js
|
||||
|
||||
'use strict';
|
||||
|
||||
// https://w3c.github.io/pointerlock/
|
||||
|
||||
promise_test(async () => {
|
||||
const html = await fetch('/interfaces/html.idl').then(r => r.text());
|
||||
const dom = await fetch('/interfaces/dom.idl').then(r => r.text());
|
||||
const uievents = await fetch('/interfaces/uievents.idl').then(r => r.text());
|
||||
const idl = await fetch('/interfaces/pointerlock.idl').then(r => r.text());
|
||||
|
||||
const idl_array = new IdlArray();
|
||||
idl_array.add_idls(idl);
|
||||
idl_array.add_dependency_idls(uievents);
|
||||
idl_array.add_dependency_idls(dom);
|
||||
idl_array.add_dependency_idls(html);
|
||||
|
||||
idl_array.add_objects({
|
||||
Document: ["window.document"],
|
||||
Element: ["window.document.documentElement"],
|
||||
MouseEvent: ["new MouseEvent('foo')"]
|
||||
});
|
||||
idl_array.test();
|
||||
}, 'pointerlock interfaces.');
|
Загрузка…
Ссылка в новой задаче