mirror of
https://github.com/servo/servo.git
synced 2025-08-16 19:05:33 +01:00
Implement HTMLImageElement decode (#31269)
* Implement HTMLImageElement decode
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Fix Decode doc link
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Temp
* Decode HTML Image
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Fix doc link
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Move image decode to process_image_response_for_environment_change
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Update some wpt test result
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Handle multiple image decode promises
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Remove unnecessary promise calls
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Update more wpt test result
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Undo body-size-cross-origin.https.html.ini changes
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Reject decode when src and srcset are missing
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Revert "Reject decode when src and srcset are missing"
This reverts commit 1b57ab978f9fc24facafc8af97ee8851d5142533.
* Drain promises vec and run update_the_image_data when element is created
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* resolve decode promise in abort_request when request is CompletelyAvailable
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Update wpt test
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Move storing promise in decode task
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Remove the resolve logic from decode task
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Revert "Remove the resolve logic from decode task"
This reverts commit eee6096d50
.
* reject or reject current promise before storing it
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
* Add comment to explain why resolve promise when state is CompletelyAvailable
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
---------
Signed-off-by: Bentaimia Haddadi <haddadi.taym@gmail.com>
This commit is contained in:
parent
43df0a48ee
commit
1d048f4f6a
17 changed files with 97 additions and 173 deletions
|
@ -3558,9 +3558,6 @@
|
|||
[HTMLFrameElement interface: attribute frameBorder]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement interface: new Image() must inherit property "decode()" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLTableColElement interface: document.createElement("col") must inherit property "width" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -4248,9 +4245,6 @@
|
|||
[HTMLInputElement interface: createInput("hidden") must inherit property "autocomplete" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement interface: document.createElement("img") must inherit property "decode()" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLAreaElement interface: document.createElement("area") must inherit property "username" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,5 +1,2 @@
|
|||
[image-decode-image-document.html]
|
||||
expected: ERROR
|
||||
[HTMLImageElement.prototype.decode(), image document tests. Decode from iframe with image document, succeeds (img not loaded)]
|
||||
expected: TIMEOUT
|
||||
|
||||
|
|
|
@ -1,26 +1,11 @@
|
|||
[image-decode-path-changes.html]
|
||||
type: testharness
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode; following good png decode succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode; following good svg decode succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode; following bad decode fails.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes to the same path succeed.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. srcset changes fail decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. srcset changes fail decode; following good decode succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. srcset changes fail decode; following bad decode fails.]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,26 +1,5 @@
|
|||
[image-decode-picture.html]
|
||||
type: testharness
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with PNG source decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with multiple sources decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with PNG data URL source decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with SVG source decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Non-existent source fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Corrupt image in src fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image without srcset fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Multiple decodes for images with src succeed.]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,4 +1,2 @@
|
|||
[image-decode-with-quick-attach.html]
|
||||
[HTMLImageElement.prototype.decode(), attach to DOM before promise resolves.]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,44 +1,8 @@
|
|||
[image-decode.html]
|
||||
type: testharness
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with PNG src decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with PNG data URL src decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with SVG src decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Non-existent src fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Inactive document fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Adopted active image into inactive document fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Adopted inactive image into active document succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Corrupt image in src fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image without src/srcset fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Multiple decodes for images with src succeed.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with PNG srcset decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with SVG srcset decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Non-existent srcset fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Multiple decodes for images with srcset succeed.]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -5,9 +5,6 @@
|
|||
[Retrieving a same-origin resource with Timing-Allow-Origin should expose body size]
|
||||
expected: FAIL
|
||||
|
||||
[Retrieving a no-cors resource without Timing-Allow-Origin should not expose body size]
|
||||
expected: FAIL
|
||||
|
||||
[Retrieving a no-cors resource with Timing-Allow-Origin should not expose body size]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -3381,9 +3381,6 @@
|
|||
[HTMLFrameElement interface: attribute frameBorder]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement interface: new Image() must inherit property "decode()" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLTableColElement interface: document.createElement("col") must inherit property "width" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
|
@ -4044,9 +4041,6 @@
|
|||
[HTMLTableColElement interface: document.createElement("colgroup") must inherit property "chOff" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement interface: document.createElement("img") must inherit property "decode()" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLAreaElement interface: document.createElement("area") must inherit property "username" with the proper type]
|
||||
expected: FAIL
|
||||
|
||||
|
|
|
@ -1,4 +1 @@
|
|||
[image-decode-image-document.html]
|
||||
expected: ERROR
|
||||
[HTMLImageElement.prototype.decode(), image document tests. Decode from iframe with image document, succeeds (img not loaded)]
|
||||
expected: TIMEOUT
|
||||
|
|
|
@ -1,24 +1,9 @@
|
|||
[image-decode-path-changes.html]
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode; following good png decode succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode; following good svg decode succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes fail decode; following bad decode fails.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. src changes to the same path succeed.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. srcset changes fail decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. srcset changes fail decode; following good decode succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), src/srcset mutation tests. srcset changes fail decode; following bad decode fails.]
|
||||
expected: FAIL
|
||||
|
|
|
@ -1,24 +1,3 @@
|
|||
[image-decode-picture.html]
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with PNG source decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with multiple sources decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with PNG data URL source decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image with SVG source decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Non-existent source fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Corrupt image in src fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Image without srcset fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), picture tests. Multiple decodes for images with src succeed.]
|
||||
expected: FAIL
|
||||
|
|
|
@ -1,3 +1 @@
|
|||
[image-decode-with-quick-attach.html]
|
||||
[HTMLImageElement.prototype.decode(), attach to DOM before promise resolves.]
|
||||
expected: FAIL
|
||||
|
|
|
@ -1,42 +1,6 @@
|
|||
[image-decode.html]
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with PNG src decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with PNG data URL src decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with SVG src decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Non-existent src fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Inactive document fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Adopted active image into inactive document fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Adopted inactive image into active document succeeds.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Corrupt image in src fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image without src/srcset fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Multiple decodes for images with src succeed.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with PNG srcset decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Image with SVG srcset decodes with undefined.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Non-existent srcset fails decode.]
|
||||
expected: FAIL
|
||||
|
||||
[HTMLImageElement.prototype.decode(), basic tests. Multiple decodes for images with srcset succeed.]
|
||||
expected: FAIL
|
||||
|
|
|
@ -5,9 +5,6 @@
|
|||
[Retrieving a same-origin resource with Timing-Allow-Origin should expose body size]
|
||||
expected: FAIL
|
||||
|
||||
[Retrieving a no-cors resource without Timing-Allow-Origin should not expose body size]
|
||||
expected: FAIL
|
||||
|
||||
[Retrieving a no-cors resource with Timing-Allow-Origin should not expose body size]
|
||||
expected: FAIL
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue