Changeset 269155 in webkit
- Timestamp:
- Oct 29, 2020, 10:53:22 AM (6 years ago)
- Location:
- trunk
- Files:
-
- 4 added
- 3 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/fast/images/image-orientation-none-data-url-expected.txt (added)
-
LayoutTests/fast/images/image-orientation-none-data-url.html (added)
-
LayoutTests/fast/images/image-orientation-none-local-expected.txt (added)
-
LayoutTests/fast/images/image-orientation-none-local.html (added)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/html/HTMLImageElement.cpp (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r269148 r269155 1 2020-10-29 Noam Rosenthal <noam@webkit.org> 2 3 REGRESSION(r268249): image-orientation:none is broken for local (file://) urls 4 https://bugs.webkit.org/show_bug.cgi?id=217808 5 <rdar://problem/70603407> 6 7 Reviewed by Myles C. Maxfield. 8 9 Added a tests that ensure image-orientation: none is supported in file and data URLs. 10 11 * fast/images/image-orientation-none-local-expected.txt: Added. 12 * fast/images/image-orientation-none-local.html: Added. 13 * fast/images/image-orientation-none-data-url-expected.txt: Added. 14 * fast/images/image-orientation-none-data-url.html: Added. 15 1 16 2020-10-29 Karl Rackler <rackler@apple.com> 2 17 -
trunk/Source/WebCore/ChangeLog
r269153 r269155 1 2020-10-29 Noam Rosenthal <noam@webkit.org> 2 3 REGRESSION(r268249): image-orientation:none is broken for local (file://) urls 4 https://bugs.webkit.org/show_bug.cgi?id=217808 5 <rdar://problem/70603407> 6 7 Reviewed by Myles C. Maxfield. 8 9 Use isCORSSameOrigin() instead of isOriginClean(), it's a more accureate method 10 for this purpose. 11 Allow image-orientation: none overriding when the image is local or a data-url. 12 13 Test: fast/images/image-orientation-none-local.html 14 15 * html/HTMLImageElement.cpp: 16 (WebCore::HTMLImageElement::allowsOrientationOverride const): 17 1 18 2020-10-29 Antti Koivisto <antti@apple.com> 2 19 -
trunk/Source/WebCore/html/HTMLImageElement.cpp
r268249 r269155 684 684 bool HTMLImageElement::allowsOrientationOverride() const 685 685 { 686 auto* image = cachedImage(); 687 return !image || image->isOriginClean(&(document().securityOrigin())); 686 auto* cachedImage = this->cachedImage(); 687 if (!cachedImage) 688 return true; 689 690 auto image = cachedImage->image(); 691 return !image || image->sourceURL().protocolIsData() || cachedImage->isCORSSameOrigin(); 688 692 } 689 693
Note:
See TracChangeset
for help on using the changeset viewer.