Bug 119055
| Summary: | Document::setContentLanguage should not call styleResolverChanged | ||
|---|---|---|---|
| Product: | WebKit | Reporter: | Ryosuke Niwa <rniwa> |
| Component: | Layout and Rendering | Assignee: | Nobody <webkit-unassigned> |
| Status: | RESOLVED CONFIGURATION CHANGED | ||
| Severity: | Normal | CC: | ahmad.saleem792, ap, bdakin, bfulgham, dino, hyatt, mmaxfield, simon.fraser, zalan |
| Priority: | P2 | Keywords: | BlinkMergeCandidate |
| Version: | 528+ (Nightly build) | ||
| Hardware: | Unspecified | ||
| OS: | Unspecified | ||
| Bug Depends on: | 76701 | ||
| Bug Blocks: | |||
Ryosuke Niwa
Consider merging https://chromium.googlesource.com/chromium/blink/+/669007b54d9434eac10d50bc0981ad1dd6970e33
Document::setContentLanguage was calling styleResolverChanged just to update the root
style so we'll go through StyleResolver::styleForDocument which does not appear to be needed.
We only need to Force a recalc on the whole document so all the lang and locale related styles
are picked correctly.
This code came from https://bugs.webkit.org/show_bug.cgi?id=76701 where it was originally
recalcStyle(Force) in the patch and then through a series of review confusions it ended up as
a call to update the entire style resolver instead of just scheduling a forced style recalc.
| Attachments | ||
|---|---|---|
| Add attachment proposed patch, testcase, etc. |
Ahmad Saleem
The Chromium / Blink patch is trying to modify following:
https://github.com/WebKit/WebKit/blob/d03ed349d77c73455b7ba94aa908b7dc0a5eddc8/Source/WebCore/dom/Document.cpp#L1544
This comment still exist:
// Recalculate style so language is used when selecting the initial font.
Plus this commit changed:
"scheduleForcedStyleRecalc" to "scheduleFullStyleRebuild"
______
Just wanted to share updated information. Thanks!
Ryosuke Niwa
We do this already. No need to merge.