Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(923)

Unified Diff: webkit/data/layout_tests/chrome/fast/events/contextmenu-event-ordering.html

Issue 55025: Remove tests that have been upstreamed. Update test_expectations list... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webkit/data/layout_tests/chrome/fast/events/contextmenu-event-ordering.html
===================================================================
--- webkit/data/layout_tests/chrome/fast/events/contextmenu-event-ordering.html (revision 12362)
+++ webkit/data/layout_tests/chrome/fast/events/contextmenu-event-ordering.html (working copy)
@@ -1,71 +0,0 @@
-<html>
- <head>
- <title>Context menu event ordering</title>
- <style>
- #clickTarget {
- width: 100%;
- height: 50px;
- background: red;
- text-align: center;
- }
- </style>
- <script>
-
- function startTest() {
- var target = document.getElementById("clickTarget");
-
- traceMouseEvent(target, "click");
- traceMouseEvent(target, "mousedown");
- traceMouseEvent(target, "mouseup");
- traceMouseEvent(target, "contextmenu");
-
- if (window.layoutTestController) {
- window.layoutTestController.dumpAsText();
-
- // Right click inside clickTarget
- window.eventSender.mouseMoveTo(20,20);
- window.eventSender.mouseDown(2 /*right button*/);
- window.eventSender.mouseUp(2 /*right button*/);
- }
- }
-
- function traceMouseEvent(target, eventName) {
-
- var callback = function(e) {
- log ("Dispatched event " + e.type + " (button=" + e.button + ")");
-
- if (eventName == "contextmenu") {
- // Prevent the context menu from being displayed.
- e.returnValue = false;
- if (e.stopPropagation) {
- e.stopPropagation();
- }
- }
- };
-
- if (target.addEventListener) {
- target.addEventListener(eventName, callback, false);
- } else if (target.attachEvent) /*Internet Explorer*/ {
- target.attachEvent("on" + eventName, callback);
- } else {
- log ("!!! Failed registering " + eventName);
- }
- }
-
- function log(msg) {
- var log = document.getElementById("log");
- log.appendChild(document.createTextNode(msg));
- log.appendChild(document.createElement("br"));
- }
- </script>
- </head>
-
- <body onload="startTest()">
- <div id=clickTarget>
- [Click target]
- </div>
-
- <p>Right click in the red box: the event sequence should match (mousedown, mouseup, contextmenu)</p>
- <pre id=log></pre>
- </body>
-</html>

Powered by Google App Engine
This is Rietveld 408576698