layout: Allow lazy resolution of automatic minimum sizes (#35965)

`Size::resolve_for_min()` had an `Au` parameter, representing the value
to be used for an automatic minimum size. However, this amount isn't
trivial to compute in flexbox, so this patch changes the parameter to a
function that can be called lazily.

Note flexbox isn't currently using `Size::resolve_for_min()`, but it
will in #35961.

Signed-off-by: Oriol Brufau <obrufau@igalia.com>
This commit is contained in:
Oriol Brufau 2025-03-13 23:50:16 +01:00 committed by GitHub
parent 62d6759106
commit 7cf2fc88a0
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
5 changed files with 20 additions and 20 deletions

View file

@ -793,7 +793,7 @@ impl AbsoluteAxisSolver<'_> {
SizeConstraint::Definite(self.computed_sizes.resolve(
self.axis,
initial_behavior,
Au::zero(),
Au::zero,
Some(stretch_size),
get_content_size,
self.is_table,