12018-01-25 Said Abou-Hallawa <sabouhallawa@apple.com>
2
3 REGRESSION(r217236): [iOS] PDFDocumentImage does not update its cached ImageBuffer if it has a sub-rectangle of the image
4 https://bugs.webkit.org/show_bug.cgi?id=182083
5
6 Reviewed by NOBODY (OOPS!).
7
8 Revert the change r217236 back and fix the issue of throwing the cached
9 ImageBuffer of the PDF document because of moving its rectangle.
10
11 Test: fast/images/pdf-as-image-dest-rect-change.html
12
13 * platform/graphics/cg/PDFDocumentImage.cpp:
14 (WebCore::PDFDocumentImage::cacheParametersMatch const):
15 (WebCore::PDFDocumentImage::updateCachedImageIfNeeded):
16 * platform/graphics/cg/PDFDocumentImage.h:
17 * testing/Internals.cpp:
18 (WebCore::pdfDocumentImageFromImageElement):
19 (WebCore::Internals::pdfDocumentCachingCount):
20 * testing/Internals.h:
21 * testing/Internals.idl:
22