Source code

Revision control

Copy as Markdown

Other Tools

<meta charset="utf-8">
<meta name="viewport" content="user-scalable=no"/>
<title>Check that double tapping inside an oop iframe doesn't work if the top
level content document doesn't allow zooming</title>
<script src="apz_test_native_event_utils.js"></script>
<script src="apz_test_utils.js"></script>
<script src="/tests/SimpleTest/paint_listener.js"></script>
async function test() {
let useTouchpad = ( == "?touchpad");
let resolution = await getResolution();
ok(resolution > 0,
"The initial_resolution is " + resolution + ", which is some sane value");
// Set up a Promise waiting for a TransformEnd which should never happen.
promiseTransformEnd().then(() => {
ok(false, "No TransformEnd should happen!");
// A double tap inside the OOP iframe.
await synthesizeDoubleTap(document.getElementById("target"), 20, 20, useTouchpad);
for (let i = 0; i < 10; i++) {
await promiseFrame();
// Flush state just in case.
await promiseApzFlushedRepaints();
let prev_resolution = resolution;
resolution = await getResolution();
is(resolution, prev_resolution, "No zoom should happen");
.then(subtestDone, subtestFailed);
iframe {
margin: 0;
padding: 0;
border: 1px solid black;
<iframe id="target" width="100" height="100" src=""></iframe>