mirror of
https://github.com/servo/servo.git
synced 2025-08-06 06:00:15 +01:00
Auto merge of #16913 - jdm:canvas2d, r=jdm
Make canvas origin clean checks use origin of image response Adapted from #15887. --- - [X] `./mach build -d` does not report any errors - [X] `./mach test-tidy` does not report any errors - [X] These changes fix #15409 - [X] There are tests for these changes <!-- Reviewable:start --> --- This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/16913) <!-- Reviewable:end -->
This commit is contained in:
commit
62690887c1
21 changed files with 78 additions and 92 deletions
|
@ -677,8 +677,8 @@ impl WebGLRenderingContext {
|
|||
let window = window_from_node(&*self.canvas);
|
||||
|
||||
let img = match canvas_utils::request_image_from_cache(&window, img_url) {
|
||||
ImageResponse::Loaded(img) => img,
|
||||
ImageResponse::PlaceholderLoaded(_) | ImageResponse::None |
|
||||
ImageResponse::Loaded(img, _) => img,
|
||||
ImageResponse::PlaceholderLoaded(_, _) | ImageResponse::None |
|
||||
ImageResponse::MetadataLoaded(_)
|
||||
=> return Err(()),
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue