bug1017086_inner.html 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <!DOCTYPE HTML>
  2. <html>
  3. <!--
  4. https://bugzilla.mozilla.org/show_bug.cgi?id=1017086
  5. -->
  6. <head>
  7. <meta charset="utf-8">
  8. <title>Test for Bug 1017086</title>
  9. <meta name="author" content="Maksim Lebedev" />
  10. <script type="application/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
  11. <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css"/>
  12. <script type="application/javascript">
  13. /** Test for Bug 1017086 **/
  14. var testelem = undefined;
  15. var pointer_events = ["onpointerover", "onpointerenter",
  16. "onpointermove",
  17. "onpointerdown", "onpointerup",
  18. "onpointerout", "onpointerleave",
  19. "onpointercancel"];
  20. function check(expected_value, event_name, container, container_name) {
  21. var text = event_name + " in " + container_name + " should be " + expected_value;
  22. parent.is(event_name in container, expected_value, text);
  23. }
  24. function runTest() {
  25. testelem = document.getElementById("test");
  26. is(!!testelem, true, "Document should have element with id 'test'");
  27. parent.turnOnOffPointerEvents( function() {
  28. parent.part_of_checks(pointer_events, check, window, document, testelem);
  29. });
  30. }
  31. </script>
  32. </head>
  33. <body onload="runTest();">
  34. <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=1017086">Mozilla Bug 1017086</a>
  35. <p id="display"></p>
  36. <div id="content" style="display: none">
  37. </div>
  38. <pre id="test">
  39. </pre>
  40. </body>
  41. </html>