5 <meta name=
"viewport" content=
"width=device-width,initial-scale=1.0">
6 <title>Touch Action Test Page
</title>
9 <div id=
"events">events:
</div>
11 We need some padding here so that the page is large enough to test swipe
14 <div id=
"bottom">This is the bottom of the page.
</div>
16 events
= document
.getElementById('events');
17 var eventTypes
= ['touchstart', 'touchend', 'touchmove', 'touchcancel'];
18 var eventListener = function(evt
) {
19 events
.innerHTML
+= ' ' + evt
.type
;
22 for (var i
= 0; i
< eventTypes
.length
; i
++) {
23 events
.addEventListener(eventTypes
[i
], eventListener
);
26 var padding
= document
.getElementById('padding');
27 padding
.style
.border
= 'solid';
28 padding
.style
.height
= window
.screen
.height
* 2 + 'px';