mirror of
https://github.com/servo/servo.git
synced 2025-09-30 00:29:14 +01:00
layout: Refactor InlineFormattingContextBuilder::is_empty
(#39048)
This method could iterate all the items in the inline formatting context that was being created. This patch turns it into a field, replacing `has_uncollapsible_text_content` (so this doesn't increase memory). Testing: Not needed, no behavior change Signed-off-by: Oriol Brufau <obrufau@igalia.com>
This commit is contained in:
parent
a586f4b53f
commit
ec1b9b2480
2 changed files with 23 additions and 43 deletions
|
@ -588,7 +588,7 @@ impl<'dom> BlockContainerBuilder<'dom, '_> {
|
|||
box_slot: BoxSlot<'dom>,
|
||||
) {
|
||||
if let Some(builder) = self.inline_formatting_context_builder.as_mut() {
|
||||
if !builder.is_empty() {
|
||||
if !builder.is_empty {
|
||||
let constructor = || {
|
||||
ArcRefCell::new(AbsolutelyPositionedBox::construct(
|
||||
self.context,
|
||||
|
@ -625,7 +625,7 @@ impl<'dom> BlockContainerBuilder<'dom, '_> {
|
|||
box_slot: BoxSlot<'dom>,
|
||||
) {
|
||||
if let Some(builder) = self.inline_formatting_context_builder.as_mut() {
|
||||
if !builder.is_empty() {
|
||||
if !builder.is_empty {
|
||||
let constructor = || {
|
||||
ArcRefCell::new(FloatBox::construct(
|
||||
self.context,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue