WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
33968
Canvas: Exception erroneously thrown for drawImage() when image.complete=false
https://bugs.webkit.org/show_bug.cgi?id=33968
Summary
Canvas: Exception erroneously thrown for drawImage() when image.complete=false
Kai Hendry
Reported
2010-01-21 12:42:20 PST
Just tried
http://roulette.dabase.com/
on
r53596
and it also fails to render, while Gecko and Presto can. I can work around on this problem by adding a timeout. There is some bizaare DOM ready bug I guess.
Attachments
Proposed patch
(5.87 KB, patch)
2010-06-29 07:51 PDT
,
Andreas Kling
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Andreas Kling
Comment 1
2010-06-29 07:16:56 PDT
Both the site and WebKit are at fault here. The page is using $(document).ready() instead of $(window).load() - $d(document).ready() fires as soon as the DOM is ready instead of waiting for subresources (images in this case) to finish loading. However, since the image element passed to drawImage() has complete=false, nothing should be done (HTML5 4.8.11), so the exception is thrown in error. Patch coming in a moment.
Andreas Kling
Comment 2
2010-06-29 07:51:59 PDT
Created
attachment 60021
[details]
Proposed patch Implement correct behavior for drawImage() with incomplete image or video. Autotest included. Spec link:
http://www.whatwg.org/specs/web-apps/current-work/#dom-context-2d-drawimage
Andreas Kling
Comment 3
2010-07-01 07:57:40 PDT
For future visitors to this bug, the page at
http://roulette.dabase.com/
has now been updated to use $(window).load() :-)
WebKit Commit Bot
Comment 4
2010-07-01 10:29:41 PDT
Comment on
attachment 60021
[details]
Proposed patch Clearing flags on attachment: 60021 Committed
r62273
: <
http://trac.webkit.org/changeset/62273
>
WebKit Commit Bot
Comment 5
2010-07-01 10:29:46 PDT
All reviewed patches have been landed. Closing bug.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug