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

Side by Side Diff: content/test/data/gpu/pixel_canvas2d_webgl.html

Issue 2503453003: Remove all calls to domAutomationController.setAutomationId.
Patch Set: Fix nacl_browsertest_util.cc Created 3 years, 5 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
OLDNEW
1 <!DOCTYPE HTML> 1 <!DOCTYPE HTML>
2 2
3 <!-- READ BEFORE UPDATING: 3 <!-- READ BEFORE UPDATING:
4 If this test is updated make sure to increment the "revision" value of the 4 If this test is updated make sure to increment the "revision" value of the
5 associated test in content/test/gpu/page_sets/pixel_tests.py. This will ensure 5 associated test in content/test/gpu/page_sets/pixel_tests.py. This will ensure
6 that the baseline images are regenerated on the next run. 6 that the baseline images are regenerated on the next run.
7 --> 7 -->
8 8
9 <html> 9 <html>
10 <head> 10 <head>
(...skipping 16 matching lines...) Expand all
27 canvas.style.width = canvas.style.height = "150px"; 27 canvas.style.width = canvas.style.height = "150px";
28 var c2d = canvas.getContext("2d"); 28 var c2d = canvas.getContext("2d");
29 c2d.clearRect(0, 0, canvas.width, canvas.height); 29 c2d.clearRect(0, 0, canvas.width, canvas.height);
30 c2d.fillStyle = "rgba(255, 0, 0, 0.5)"; 30 c2d.fillStyle = "rgba(255, 0, 0, 0.5)";
31 c2d.fillRect(50, 50, 100, 100); 31 c2d.fillRect(50, 50, 100, 100);
32 32
33 var webglCanvas = document.getElementById("c2"); 33 var webglCanvas = document.getElementById("c2");
34 gl = initGL(webglCanvas); 34 gl = initGL(webglCanvas);
35 if (!gl) { 35 if (!gl) {
36 console.log('Failed to initialize GL from canvas: ' + webglCanvas); 36 console.log('Failed to initialize GL from canvas: ' + webglCanvas);
37 domAutomationController.setAutomationId(1);
38 domAutomationController.send("FAILURE"); 37 domAutomationController.send("FAILURE");
39 return; 38 return;
40 } 39 }
41 40
42 if (!setup(gl)) { 41 if (!setup(gl)) {
43 console.log('Failed to set up GL: ' + gl); 42 console.log('Failed to set up GL: ' + gl);
44 domAutomationController.setAutomationId(1);
45 domAutomationController.send("FAILURE"); 43 domAutomationController.send("FAILURE");
46 return; 44 return;
47 } 45 }
48 46
49 gl.viewport(0, 0, 50, 50); 47 gl.viewport(0, 0, 50, 50);
50 48
51 waitForFinish(); 49 waitForFinish();
52 } 50 }
53 51
54 function waitForFinish() 52 function waitForFinish()
55 { 53 {
56 if (g_swapsBeforeAck == 0) { 54 if (g_swapsBeforeAck == 0) {
57 domAutomationController.setAutomationId(1);
58 domAutomationController.send("SUCCESS"); 55 domAutomationController.send("SUCCESS");
59 } else { 56 } else {
60 g_swapsBeforeAck--; 57 g_swapsBeforeAck--;
61 document.getElementById('container').style.zIndex = g_swapsBeforeAck + 1; 58 document.getElementById('container').style.zIndex = g_swapsBeforeAck + 1;
62 drawTriangle(gl); 59 drawTriangle(gl);
63 window.requestAnimationFrame(waitForFinish); 60 window.requestAnimationFrame(waitForFinish);
64 } 61 }
65 } 62 }
66 </script> 63 </script>
67 </head> 64 </head>
68 <body onload="main()"> 65 <body onload="main()">
69 <div style="position:relative; width:300px; height:300px; background-color:black "> 66 <div style="position:relative; width:300px; height:300px; background-color:black ">
70 </div> 67 </div>
71 <div id="container" style="position:absolute; top:0px; left:0px"> 68 <div id="container" style="position:absolute; top:0px; left:0px">
72 <canvas id="c2" width="50" height="50" class="nomargin"></canvas> 69 <canvas id="c2" width="50" height="50" class="nomargin"></canvas>
73 <!-- 70 <!--
74 Canvas acceleration requires that the canvas be at least 256x257. 71 Canvas acceleration requires that the canvas be at least 256x257.
75 --> 72 -->
76 <canvas id="c" width="300" height="300" class="nomargin"></canvas> 73 <canvas id="c" width="300" height="300" class="nomargin"></canvas>
77 </div> 74 </div>
78 </body> 75 </body>
79 </html> 76 </html>
OLDNEW
« no previous file with comments | « content/test/data/gpu/pixel_canvas2d_untagged.html ('k') | content/test/data/gpu/pixel_canvas_display_linear-rgb.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698