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

Side by Side Diff: LayoutTests/fast/events/pointer-events.html

Issue 14859016: Don't force layout for mouse event hit tests (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: fix review comment Created 7 years, 7 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" 1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN"
2 "http://www.w3.org/TR/html4/strict.dtd"> 2 "http://www.w3.org/TR/html4/strict.dtd">
3 <html> 3 <html>
4 <head> 4 <head>
5 <meta http-equiv="Content-type" content="text/html; charset=utf-8"> 5 <meta http-equiv="Content-type" content="text/html; charset=utf-8">
6 <title>Test for pointer-events property</title> 6 <title>Test for pointer-events property</title>
7 <style type="text/css" media="screen"> 7 <style type="text/css" media="screen">
8 p { 8 p {
9 position: absolute; 9 position: absolute;
10 width: 100px; 10 width: 100px;
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 43
44 var hit = document.createElement('p'); 44 var hit = document.createElement('p');
45 hit.style.left = "140px"; 45 hit.style.left = "140px";
46 hit.style.top = yOffset + "px"; 46 hit.style.top = yOffset + "px";
47 hit.id = "text" + pointerEventsValues[pi]; 47 hit.id = "text" + pointerEventsValues[pi];
48 hit.appendChild(document.createTextNode("-miss-")); 48 hit.appendChild(document.createTextNode("-miss-"));
49 49
50 testContent.appendChild(hit); 50 testContent.appendChild(hit);
51 51
52 if (window.eventSender) { 52 if (window.eventSender) {
53 // Mouse events only work after an initial layout
54 document.body.offsetLeft;
53 // Cell click 55 // Cell click
54 eventSender.mouseMoveTo(15, yOffset + 10); 56 eventSender.mouseMoveTo(15, yOffset + 10);
55 eventSender.mouseDown(); 57 eventSender.mouseDown();
56 eventSender.mouseUp(); 58 eventSender.mouseUp();
57 } 59 }
58 60
59 yOffset += 40; 61 yOffset += 40;
60 } 62 }
61 } 63 }
62 </script> 64 </script>
63 65
64 </head> 66 </head>
65 <body onload="testContent()"> 67 <body onload="testContent()">
66 <h1>Testing the values of 'pointer-events' on HTML content</h1> 68 <h1>Testing the values of 'pointer-events' on HTML content</h1>
67 <div>The labels on the left will be clicked and the result is shown to the rig ht</div> 69 <div>The labels on the left will be clicked and the result is shown to the rig ht</div>
68 <div id="test-content"> 70 <div id="test-content">
69 </div> 71 </div>
70 </body> 72 </body>
71 </html> 73 </html>
OLDNEW
« no previous file with comments | « LayoutTests/fast/events/mouseup-outside-document.html ('k') | LayoutTests/fast/events/pointer-events-2.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698