LCL: ChildSizing, remove restriction that child controls with "AutoSized=True" are not enlarged. (This did not work, due to bugs in constrains code / but now constrains code is fixed / This restores the old behaviour)

This commit is contained in:
Martin 2024-03-24 15:49:06 +01:00
parent 2a04d89400
commit da3a1abb9a

View File

@ -1417,19 +1417,6 @@ begin
PreferredSize[asboVertical]:=
Control.Constraints.MinMaxHeight(PreferredSize[asboVertical]);
if IsPrefWidthValid
and (Control.AutoSize or (Control.BorderSpacing.CellAlignHorizontal<>ccaFill))
then begin
// the control.width is fixed to its preferred width
MaximumSize[asboHorizontal]:=PreferredSize[asboHorizontal];
end;
if IsPrefHeightValid
and (Control.AutoSize or (Control.BorderSpacing.CellAlignVertical<>ccaFill))
then begin
// the control.height is fixed to its preferred height
MaximumSize[asboVertical]:=PreferredSize[asboVertical];
end;
// if no preferred size is valid use the class defaults
if not IsPrefWidthValid then
PreferredSize[asboHorizontal]:=