Bug 214426

Summary: REGRESSION (r261874): Typing near the bottom of a scrollable document causes the scroll position to jump
Product: WebKit Reporter: Wenson Hsieh <wenson_hsieh>
Component: HTML EditingAssignee: Wenson Hsieh <wenson_hsieh>
Status: RESOLVED FIXED    
Severity: Normal CC: ews-watchlist, mifenton, simon.fraser, thorton, webkit-bug-importer, wenson_hsieh
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
For EWS
none
For EWS
simon.fraser: review+
Patch for landing none

Description Wenson Hsieh 2020-07-16 15:05:40 PDT
<rdar://problem/65302701>
Comment 1 Wenson Hsieh 2020-07-16 23:32:40 PDT Comment hidden (obsolete)
Comment 2 Wenson Hsieh 2020-07-20 12:25:26 PDT
Created attachment 404741 [details]
For EWS
Comment 3 Simon Fraser (smfr) 2020-07-20 13:50:01 PDT
Comment on attachment 404741 [details]
For EWS

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

> Source/WebCore/ChangeLog:17
> +        the content size of view changes; if we happen to be scrolled all the way to the bottom of the main frame, this

I'd like to see a mention of what triggers the layout that causes the content size to change.
Comment 4 Wenson Hsieh 2020-07-20 14:08:50 PDT
Comment on attachment 404741 [details]
For EWS

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

>> Source/WebCore/ChangeLog:17
>> +        the content size of view changes; if we happen to be scrolled all the way to the bottom of the main frame, this
> 
> I'd like to see a mention of what triggers the layout that causes the content size to change.

πŸ‘πŸ» added this information to the ChangeLog.

In this particular case, the layout happens right before we try and canonicalize under the constructor of VisiblePosition. However, it’s not always due to this; the content size may also change due to script (e.g. input event listeners) triggering layout (for instance, by asking for scrollHeight).
Comment 5 Wenson Hsieh 2020-07-20 14:44:34 PDT
Created attachment 404759 [details]
Patch for landing
Comment 6 EWS 2020-07-20 15:54:03 PDT
Committed r264627: <https://trac.webkit.org/changeset/264627>

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