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

Unified Diff: third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-out-of-bounds-src.html

Issue 2592113003: Load data URI images in an async way according to spec (take 3) (Closed)
Patch Set: Fixed more devtools reliance on sync loading Created 3 years, 12 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: third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-out-of-bounds-src.html
diff --git a/third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-out-of-bounds-src.html b/third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-out-of-bounds-src.html
index 851733635dd90bd483c8478e419e55d35963d1fb..e2afad91a0984fd63c15b1c13338581beab15670 100644
--- a/third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-out-of-bounds-src.html
+++ b/third_party/WebKit/LayoutTests/fast/canvas/canvas-drawImage-out-of-bounds-src.html
@@ -36,15 +36,17 @@ ctx1.drawImage(bgcanvas, -100, 0, 200, 200, -25, 175, 100, 100);
ctx1.drawImage(bgcanvas, 0, 0, 100, 200, 75, 175, 100, 100);
ctx1.drawImage(bgcanvas, 0, 0, 200, 200, 175, 175, 100, 100);
-ctx2.drawImage(img, -100, -100, 300, 300, -25, -25, 300, 300);
-ctx2.drawImage(img, -100, -100, 200, 200, -25, -25, 100, 100);
-ctx2.drawImage(img, 0, -100, 100, 200, 75, -25, 100, 100);
-ctx2.drawImage(img, 0, -100, 200, 200, 175, -25, 100, 100);
-ctx2.drawImage(img, -100, 0, 200, 100, -25, 75, 100, 100);
-ctx2.drawImage(img, 0, 0, 200, 100, 175, 75, 100, 100);
-ctx2.drawImage(img, -100, 0, 200, 200, -25, 175, 100, 100);
-ctx2.drawImage(img, 0, 0, 100, 200, 75, 175, 100, 100);
-ctx2.drawImage(img, 0, 0, 200, 200, 175, 175, 100, 100);
+img.onload = function() {
+ ctx2.drawImage(img, -100, -100, 300, 300, -25, -25, 300, 300);
+ ctx2.drawImage(img, -100, -100, 200, 200, -25, -25, 100, 100);
+ ctx2.drawImage(img, 0, -100, 100, 200, 75, -25, 100, 100);
+ ctx2.drawImage(img, 0, -100, 200, 200, 175, -25, 100, 100);
+ ctx2.drawImage(img, -100, 0, 200, 100, -25, 75, 100, 100);
+ ctx2.drawImage(img, 0, 0, 200, 100, 175, 75, 100, 100);
+ ctx2.drawImage(img, -100, 0, 200, 200, -25, 175, 100, 100);
+ ctx2.drawImage(img, 0, 0, 100, 200, 75, 175, 100, 100);
+ ctx2.drawImage(img, 0, 0, 200, 200, 175, 175, 100, 100);
+}
if (window.testRunner) {
testRunner.waitUntilDone();
@@ -96,4 +98,4 @@ function imageReady(imageBitmap) {
}
</script>
-</body></html>
+</body></html>

Powered by Google App Engine
This is Rietveld 408576698