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

Side by Side Diff: LayoutTests/fast/canvas/canvas-toBlob-defaultpng.html

Issue 1257253004: [HTMLCanvasElement.toBlob] Default callback version without scheduler (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Changes based on second code reviews 2 Created 5 years, 4 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
(Empty)
1 <img id="myImg" onload="testDone()">
2 <script src = "../../resources/js-test.js"></script>
xlai (Olivia) 2015/08/21 18:40:05 Using asynchronous testing from js-test testing fr
3 <script type = 'text/javascript'>
4 if (window.testRunner) {
5 testRunner.dumpAsTextWithPixelResults();
Justin Novosad 2015/08/21 18:53:43 This should not be a pixel test. We only use pixel
6 testRunner.waitUntilDone();
7 }
8
9 function testDone() {
10 if (window.testRunner)
11 testRunner.notifyDone();
12 }
13
14 var newImg = document.getElementById("myImg");
15 var canvas = document.createElement("canvas");
16 var ctx = canvas.getContext("2d");
17 ctx.fillStyle = "#FF0000";
18 ctx.fillRect(0, 0, 150, 75);
19
20 canvas.toBlob(function(blob) {
21 url = URL.createObjectURL(blob);
22 newImg.src = url;
23 });
24 </script>
25 </head>
26 </body>
27 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698