Bug 199718 - [Text autosizing] Do not nuke the style on dynamicViewportSizeUpdate
Summary: [Text autosizing] Do not nuke the style on dynamicViewportSizeUpdate
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Layout and Rendering (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: zalan
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-07-11 12:41 PDT by zalan
Modified: 2019-07-20 06:47 PDT (History)
4 users (show)

See Also:


Attachments
Patch (14.21 KB, patch)
2019-07-11 12:43 PDT, zalan
no flags Details | Formatted Diff | Diff
Patch (19.72 KB, patch)
2019-07-19 14:24 PDT, zalan
no flags Details | Formatted Diff | Diff
Patch (18.12 KB, patch)
2019-07-19 15:07 PDT, zalan
no flags Details | Formatted Diff | Diff
Patch (18.15 KB, patch)
2019-07-20 05:52 PDT, zalan
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description zalan 2019-07-11 12:41:03 PDT
<rdar://problem/51900666>
Comment 1 zalan 2019-07-11 12:43:37 PDT
Created attachment 373938 [details]
Patch
Comment 2 zalan 2019-07-19 14:24:27 PDT
Created attachment 374495 [details]
Patch
Comment 3 zalan 2019-07-19 15:07:44 PDT
Created attachment 374501 [details]
Patch
Comment 4 Simon Fraser (smfr) 2019-07-19 15:43:16 PDT
Comment on attachment 374501 [details]
Patch

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

> Source/WebCore/page/Page.cpp:3014
> +void Page::invalidateTextAutoSizeInAllFrames()

recomputeTextAutoSizingInAllFrames

> Source/WebKit/WebProcess/WebPage/ios/WebPageIOS.mm:3362
> +    const Seconds defaultTextAutoSizingDelayOnViewportChange = 80_ms;
> +    auto textAutoSizingDelayOnViewportChange = defaultTextAutoSizingDelayOnViewportChange;
> +    if (willBeVisuallyNonEmptySoon) {
> +        // Be a bit more agressive on the first display.
> +        const Seconds shortTextAutoSizingDelayOnViewportChange = 20_ms;
> +        textAutoSizingDelayOnViewportChange = shortTextAutoSizingDelayOnViewportChange;
> +    } else if (!isVisaullyNonEmpty) {
> +        // We don't anticipate any paining after the next upcoming layout.
> +        const Seconds longTextAutoSizingDelayOnViewportChange = 100_ms;
> +        textAutoSizingDelayOnViewportChange = longTextAutoSizingDelayOnViewportChange;
> +
> +    }

Maybe wrap in a lambda
Comment 5 zalan 2019-07-20 05:48:23 PDT
<rdar://problem/53344961>
Comment 6 zalan 2019-07-20 05:52:19 PDT
Created attachment 374547 [details]
Patch
Comment 7 WebKit Commit Bot 2019-07-20 06:47:19 PDT
Comment on attachment 374547 [details]
Patch

Clearing flags on attachment: 374547

Committed r247667: <https://trac.webkit.org/changeset/247667>
Comment 8 WebKit Commit Bot 2019-07-20 06:47:20 PDT
All reviewed patches have been landed.  Closing bug.