mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Allow caching IndependentFormattingContext::inline_content_sizes()
(#33207)
For non-replaced formatting contexts, this method redirected directly to `NonReplacedFormattingContextContents::inline_content_sizes()`, which has the actual logic for the computation. Thus it was bypassing the cache, which is handled in `NonReplacedFormattingContext::inline_content_sizes()`. Therefore, this patch redirects to the latter. Signed-off-by: Oriol Brufau <obrufau@igalia.com>
This commit is contained in:
parent
2537234090
commit
dbd0a79b3e
1 changed files with 1 additions and 3 deletions
|
@ -178,9 +178,7 @@ impl IndependentFormattingContext {
|
|||
|
||||
pub fn inline_content_sizes(&mut self, layout_context: &LayoutContext) -> ContentSizes {
|
||||
match self {
|
||||
Self::NonReplaced(inner) => inner
|
||||
.contents
|
||||
.inline_content_sizes(layout_context, inner.style.effective_writing_mode()),
|
||||
Self::NonReplaced(inner) => inner.inline_content_sizes(layout_context),
|
||||
Self::Replaced(inner) => inner.contents.inline_content_sizes(&inner.style),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue