Bug 201895 - [cairo] Incorrect targetRect in BackingStoreBackendCairoImpl::scroll
Summary: [cairo] Incorrect targetRect in BackingStoreBackendCairoImpl::scroll
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Fujii Hironori
Keywords: InRadar
Depends on:
Reported: 2019-09-17 20:44 PDT by Fujii Hironori
Modified: 2019-09-18 00:58 PDT (History)
5 users (show)

See Also:

Patch (1.90 KB, patch)
2019-09-17 20:54 PDT, Fujii Hironori
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Fujii Hironori 2019-09-17 20:44:39 PDT
[cairo] Incorrect targetRect in BackingStoreBackendCairoImpl::scroll

In BackingStoreBackendCairoImpl::scroll, targetRect is calculated wrongly by shifting maxX and manxY.

>    IntRect targetRect = scrollRect;
>    targetRect.move(scrollOffset);
>    targetRect.shiftMaxXEdgeTo(targetRect.maxX() - scrollOffset.width());
>    targetRect.shiftMaxYEdgeTo(targetRect.maxY() - scrollOffset.height());

This code came from Bug 59655.

On the other hand, Bug 83309 fixed BackingStoreBackendCairoX11::scroll.

>    IntRect targetRect = scrollRect;
>    targetRect.move(scrollOffset);
>    targetRect.intersect(scrollRect);
Comment 1 Fujii Hironori 2019-09-17 20:54:23 PDT
Created attachment 379017 [details]
Comment 2 Fujii Hironori 2019-09-18 00:57:17 PDT
Comment on attachment 379017 [details]

Clearing flags on attachment: 379017

Committed r250027: <https://trac.webkit.org/changeset/250027>
Comment 3 Fujii Hironori 2019-09-18 00:57:21 PDT
All reviewed patches have been landed.  Closing bug.
Comment 4 Radar WebKit Bug Importer 2019-09-18 00:58:22 PDT