Bug 237698 - Fix WebContent jetsam that occurs when selecting text in a large e-mail
Summary: Fix WebContent jetsam that occurs when selecting text in a large e-mail
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Scrolling (show other bugs)
Version: WebKit Local Build
Hardware: iPhone / iPad iOS 15
: P2 Normal
Assignee: Ben Nham
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-03-09 21:40 PST by Ben Nham
Modified: 2022-03-11 09:40 PST (History)
5 users (show)

See Also:


Attachments
Patch (3.24 KB, patch)
2022-03-09 21:41 PST, Ben Nham
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (3.06 KB, patch)
2022-03-09 21:59 PST, Ben Nham
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ben Nham 2022-03-09 21:40:03 PST
WebContent often jetsams when selecting text in a large e-mail in MobileMail.
Comment 1 Ben Nham 2022-03-09 21:40:31 PST
rdar://88549631
Comment 2 Ben Nham 2022-03-09 21:41:20 PST
Created attachment 454314 [details]
Patch
Comment 3 Simon Fraser (smfr) 2022-03-09 21:50:39 PST
Comment on attachment 454314 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=454314&action=review

> Source/WebCore/page/FrameView.cpp:2735
> +#if PLATFORM(IOS_FAMILY)
> +        tiledBacking->prepopulateRect(FloatRect(position, exposedContentRect().size()));
> +#else
> +        auto rect = FloatRect(position, visibleContentRect().size());
> +        if (auto exposedRect = viewExposedRect()) {
> +            exposedRect->setLocation(position);
> +            rect.intersect(*exposedRect);
> +        }
> +        tiledBacking->prepopulateRect(rect);
> +#endif

I generally prefer the #ifdef to just surround the argument computation, so there's only one line that calls tiledBacking->prepopulateRect().

Are you sure you want to change the macOS behavior at this time?
Comment 4 Ben Nham 2022-03-09 21:54:45 PST
It's probably better to leave the macOS path alone since content rects work differently on that platform and we don't have evidence of this bug on macOS.

I'll submit a newer version of the patch.
Comment 5 Ben Nham 2022-03-09 21:59:05 PST
Created attachment 454315 [details]
Patch
Comment 6 EWS 2022-03-11 09:40:53 PST
Committed r291175 (248335@main): <https://commits.webkit.org/248335@main>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 454315 [details].