test_bug405632.html 1.0 KB

1234567891011121314151617181920212223242526272829303132333435
  1. <!DOCTYPE HTML>
  2. <html>
  3. <!--
  4. https://bugzilla.mozilla.org/show_bug.cgi?id=405632
  5. -->
  6. <head>
  7. <title>Test for Bug 405632</title>
  8. <script type="text/javascript" src="/tests/SimpleTest/SimpleTest.js"></script>
  9. <link rel="stylesheet" type="text/css" href="/tests/SimpleTest/test.css" />
  10. </head>
  11. <body>
  12. <a target="_blank" href="https://bugzilla.mozilla.org/show_bug.cgi?id=405632">Mozilla Bug 405632</a>
  13. <p id="display"></p>
  14. <div id="content" style="display: none">
  15. </div>
  16. <pre id="test">
  17. <script class="testbody" type="text/javascript">
  18. /** Test for Bug 405632 **/
  19. var me = document.createEvent("mouseevent");
  20. me.initMouseEvent("foo", false, false, window, 0, 100, 100, 100, 100,
  21. false, false, false, false, 0, null);
  22. ok(me.clientX == me.pageX,
  23. "mouseEvent.clientX should be the same as mouseEvent.pageX when event is initialized manually");
  24. ok(me.clientY == me.pageY,
  25. "mouseEvent.clientY should be the same as mouseEvent.pageY when event is initialized manually");
  26. </script>
  27. </pre>
  28. </body>
  29. </html>