1
    2
    3
    4
    5
    6
    7
    8
    9
   10
   11
   12
   13

content / test / data / devtools / enable_touch.html [blame]

<script>
function checkProtos(expect) {
  var allMatch = true;
  for (var obj of [window, Document.prototype, HTMLElement.prototype, SVGElement.prototype]) {
    for (var prop of ['ontouchstart', 'ontouchend', 'ontouchmove', 'ontouchcancel']) {
      var result = prop in obj;
      if (result !== expect)
        allMatch = false;
    }
  }
  return allMatch;
}
</script>