I noticed a simple typo on line 187 of ImageSkia.cpp if (srcIsFull && bitmap.shouldCacheResampling( resizedImageRect.width(), resizedImageRect.height(), destBitmapSubsetSkI.width(), destBitmapSubsetSkI.height())) { // We're supposed to resize the entire image and cache it, even though // we don't need all of it. The && in the if statement should be ||. The whole point of shouldCacheResampling is to catch cases where we're not doing the whole image.
I landed this change as part of https://bugs.webkit.org/show_bug.cgi?id=38686.
Since recently, our background image spriting does not work when element is scaled. See image attached (toolbar button images next to Elements, Resources, etc). James is saying WebKit r60391. Same code works on Mac fine.
Created attachment 57740 [details] [IMAGE] Screenshot with regression.
Reverted: Committing to http://svn.webkit.org/repository/webkit/trunk ... M WebCore/ChangeLog M WebCore/platform/graphics/skia/ImageSkia.cpp Committed r60611
Updated baselines. They were wrong (and different from Mac). Committing to http://svn.webkit.org/repository/webkit/trunk ... M LayoutTests/ChangeLog M LayoutTests/platform/chromium-linux/fast/backgrounds/size/backgroundSize15-expected.checksum M LayoutTests/platform/chromium-linux/fast/backgrounds/size/backgroundSize15-expected.png M LayoutTests/platform/chromium-linux/fast/borders/svg-as-border-image-expected.checksum M LayoutTests/platform/chromium-linux/scrollbars/listbox-scrollbar-combinations-expected.checksum M LayoutTests/platform/chromium-linux/scrollbars/overflow-scrollbar-combinations-expected.checksum M LayoutTests/platform/chromium-linux/scrollbars/overflow-scrollbar-combinations-expected.png M LayoutTests/platform/chromium-linux/svg/W3C-SVG-1.1/coords-viewattr-02-b-expected.checksum M LayoutTests/platform/chromium-linux/svg/W3C-SVG-1.1/coords-viewattr-02-b-expected.png M LayoutTests/platform/chromium-win/fast/backgrounds/size/backgroundSize15-expected.checksum M LayoutTests/platform/chromium-win/fast/backgrounds/size/backgroundSize15-expected.png M LayoutTests/platform/chromium-win/fast/borders/svg-as-border-image-expected.checksum M LayoutTests/platform/chromium-win/fast/borders/svg-as-border-image-expected.png M LayoutTests/platform/chromium-win/scrollbars/listbox-scrollbar-combinations-expected.checksum M LayoutTests/platform/chromium-win/scrollbars/listbox-scrollbar-combinations-expected.png M LayoutTests/platform/chromium-win/scrollbars/overflow-scrollbar-combinations-expected.checksum M LayoutTests/platform/chromium-win/scrollbars/overflow-scrollbar-combinations-expected.png M LayoutTests/platform/chromium-win/svg/W3C-SVG-1.1/coords-viewattr-02-b-expected.checksum M LayoutTests/platform/chromium-win/svg/W3C-SVG-1.1/coords-viewattr-02-b-expected.png Committed r60613
Is this bug fixed?
This code seems to have changed a lot since this bug was filed, so I'm not sure it's relevant anymore. John Bates added support for resizing of cropped images in http://trac.webkit.org/changeset/93580, which I think is the same bug. The relevant test now seems to be in NativeImageSkia::resizedBitmap(). Unless someone can come up with a test case which is still broken, I think we should close this bug.