1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 14:48:14 +00:00

LibWeb: Use StyleComputer::invalidate_rule_cache() directly everywhere

Get rid of the old, roundabout way of invalidating the rule cache by
incrementing the StyleSheetList "generation".

Instead, when something wants to invalidate the rule cache, just have it
directly invalidate the rule cache. This makes it much easier to see
what's happening anyway.
This commit is contained in:
Andreas Kling 2022-03-14 20:31:57 +01:00
parent 72e6bff8b8
commit 759bfbb572
6 changed files with 6 additions and 12 deletions

View file

@ -85,7 +85,7 @@ void CSSImportRule::resource_did_load()
m_style_sheet = move(sheet);
m_document->style_sheets().bump_generation();
m_document->style_computer().invalidate_rule_cache();
m_document->invalidate_style();
}