blob: 1f12576291aaef96f2c5b38bb6c164df4028f027 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
|
<!DOCTYPE html>
<style>
div {
border: black solid 1px;
}
.composited {
transform: translateZ(0);
}
.fixed {
position: fixed;
background-color: red;
width: 500px;
height: 500px;
}
.container {
overflow: scroll;
height: 200px;
background-color: gray;
}
.filler {
height: 800px;
width: 800px;
background-color: orange;
}
.squash-spacer {
position: relative;
top: 40px;
}
.target {
position: relative;
top: 80px;
height: 10px; width: 100%;
}
</style>
<script>
if (window.testRunner) {
testRunner.dumpAsTextWithPixelResults();
testRunner.waitUntilDone();
}
if (window.internals) {
window.internals.settings.setPreferCompositingToLCDTextEnabled(true);
}
function runTest() {
var clientRect = document.getElementById('targetLink').getBoundingClientRect();
x = (clientRect.left + clientRect.right) / 2;
y = (clientRect.top + clientRect.bottom) / 2;
if (window.eventSender) {
eventSender.gestureShowPress(x, y);
window.setTimeout(function() { window.testRunner.notifyDone(); }, 0);
}
}
window.onload = runTest;
</script>
<div class='fixed composited'></div>
<div class='container'>
<div class='composited'></div>
<div class='squash-spacer'></div>
<div class='target'>
<a href='#' id='targetLink'>Target Link.</a>
</div>
<div class='filler'></div>
</div>
|