DescriptionForce adding sheets and recalc for html import re-ordering.
When we remove an import link and re-insert it into the document, the
import Document and CSSStyleSheet pointers are persisted. That means the
comparison of active stylesheets is not able to figure out that the
order of the stylesheets have changed after insertion.
We fall back to re-add all sheets to the scoped resolver and recalculate
style for the whole document if we remove an import in case it is re-
inserted into the document. The assumption is that removing html imports
is very rare.
For re-ordering of link rel=stylesheet the CSSStyleSheet object is
cleared on removal and recreated on insertion. Since the active
stylesheet list keeps references to CSSStyleSheet, CSSStyleSheet
pointers will not be re-used.
R=meade@chromium.org
TEST=fast/html/imports/import-readd-*
BUG=567021
Committed: https://crrev.com/2790e7fc5577e8f434410719e00f3b55a155c981
Cr-Commit-Position: refs/heads/master@{#434374}
Patch Set 1 #Patch Set 2 : Missing reset in resetAuthorStyle() #
Dependent Patchsets: Messages
Total messages: 25 (15 generated)
|