mirror of
https://github.com/servo/servo.git
synced 2025-08-03 20:50:07 +01:00
Add reftests for fullscreen mode
This commit is contained in:
parent
871fe9306f
commit
d2862094ec
7 changed files with 123 additions and 2 deletions
|
@ -3164,8 +3164,20 @@ impl Document {
|
|||
if !pending.fullscreen_element_ready_check() {
|
||||
error = true;
|
||||
}
|
||||
// TODO fullscreen is supported
|
||||
// TODO This algorithm is allowed to request fullscreen.
|
||||
|
||||
if PREFS
|
||||
.get("dom.fullscreen.test")
|
||||
.as_boolean()
|
||||
.unwrap_or(false)
|
||||
{
|
||||
// For reftests we just take over the current window,
|
||||
// and don't try to really enter fullscreen.
|
||||
info!("Tests don't really enter fullscreen.");
|
||||
} else {
|
||||
// TODO fullscreen is supported
|
||||
// TODO This algorithm is allowed to request fullscreen.
|
||||
warn!("Fullscreen not supported yet");
|
||||
}
|
||||
|
||||
// Step 5 Parallel start
|
||||
|
||||
|
|
|
@ -6965,6 +6965,30 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"mozilla/fullscreen/reftests/fullscreen-baseline.html": [
|
||||
[
|
||||
"/_mozilla/mozilla/fullscreen/reftests/fullscreen-baseline.html",
|
||||
[
|
||||
[
|
||||
"/_mozilla/mozilla/fullscreen/reftests/fullscreen-baseline-ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
{}
|
||||
]
|
||||
],
|
||||
"mozilla/fullscreen/reftests/fullscreen-hides-others.html": [
|
||||
[
|
||||
"/_mozilla/mozilla/fullscreen/reftests/fullscreen-hides-others.html",
|
||||
[
|
||||
[
|
||||
"/_mozilla/mozilla/fullscreen/reftests/fullscreen-baseline-ref.html",
|
||||
"=="
|
||||
]
|
||||
],
|
||||
{}
|
||||
]
|
||||
],
|
||||
"mozilla/iframe/resize_after_load.html": [
|
||||
[
|
||||
"/_mozilla/mozilla/iframe/resize_after_load.html",
|
||||
|
@ -10335,6 +10359,11 @@
|
|||
{}
|
||||
]
|
||||
],
|
||||
"mozilla/fullscreen/reftests/fullscreen-baseline-ref.html": [
|
||||
[
|
||||
{}
|
||||
]
|
||||
],
|
||||
"mozilla/globals/empty.html": [
|
||||
[
|
||||
{}
|
||||
|
@ -19345,6 +19374,18 @@
|
|||
"1e3246f791df31532c32a816a14e4e3959582146",
|
||||
"testharness"
|
||||
],
|
||||
"mozilla/fullscreen/reftests/fullscreen-baseline-ref.html": [
|
||||
"7272fa8b6e84979d5fad66bfe8c906d6e714cdb4",
|
||||
"support"
|
||||
],
|
||||
"mozilla/fullscreen/reftests/fullscreen-baseline.html": [
|
||||
"80503a9befe86e8cbd109eaf870f41c92a1952b2",
|
||||
"reftest"
|
||||
],
|
||||
"mozilla/fullscreen/reftests/fullscreen-hides-others.html": [
|
||||
"83a9abd907fc899dcfb60bab24691feb25878f7c",
|
||||
"reftest"
|
||||
],
|
||||
"mozilla/getBoundingClientRect.html": [
|
||||
"a8e92d836330126f6ccc4a13354368e223d260da",
|
||||
"testharness"
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
prefs: ["dom.fullscreen.test:true"]
|
|
@ -0,0 +1,3 @@
|
|||
[fullscreen-hides-others.html]
|
||||
type: reftest
|
||||
expected: FAIL
|
|
@ -0,0 +1,15 @@
|
|||
<!doctype html>
|
||||
<head>
|
||||
<meta charset=utf-8>
|
||||
<title>Baseline fullscreen reference</title>
|
||||
<style>
|
||||
div {
|
||||
position: fixed; top: 0; left: 0;
|
||||
height: 100%; width: 100%;
|
||||
background: green;
|
||||
}
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div>0</div>
|
||||
</body>
|
|
@ -0,0 +1,18 @@
|
|||
<!doctype html>
|
||||
<head>
|
||||
<meta charset=utf-8>
|
||||
<title>Baseline fullscreen</title>
|
||||
<link rel=match href=fullscreen-baseline-ref.html>
|
||||
<style>
|
||||
div { background: red; }
|
||||
#it { background: green; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div>-1</div>
|
||||
<div id="it">0</div>
|
||||
<div>1</div>
|
||||
</body>
|
||||
<script>
|
||||
document.getElementById("it").requestFullscreen();
|
||||
</script>
|
|
@ -0,0 +1,31 @@
|
|||
<!doctype html>
|
||||
<head>
|
||||
<meta charset=utf-8>
|
||||
<title>Elements which try to get in front of fullscreen</title>
|
||||
<link rel=match href=fullscreen-baseline-ref.html>
|
||||
<style>
|
||||
div { background: red; }
|
||||
#it { background: green; }
|
||||
|
||||
/* Fixed elements should not show up in front of fullscreen elements */
|
||||
.fixed { position: fixed; top: 0; left: 0; background: blue; }
|
||||
|
||||
/* Elements with a large z-index (even the maximum u32)
|
||||
should not show up in front of fullscreen elements */
|
||||
.zindex { z-index: 4294967295; background: yellow; }
|
||||
</style>
|
||||
</head>
|
||||
<body>
|
||||
<div>-4</div>
|
||||
<div class="fixed zindex">-3</div>
|
||||
<div class="fixed">-2</div>
|
||||
<div class="zindex">-1</div>
|
||||
<div id="it">0</div>
|
||||
<div>1</div>
|
||||
<div class="fixed zindex">2</div>
|
||||
<div class="fixed">3</div>
|
||||
<div class="zindex">4</div>
|
||||
</body>
|
||||
<script>
|
||||
document.getElementById("it").requestFullscreen();
|
||||
</script>
|
Loading…
Add table
Add a link
Reference in a new issue