mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-15 08:29:32 +02:00
LCL: TSizeConstraints: not resetting MinWidth when setting MaxWidth to 0
git-svn-id: trunk@14476 -
This commit is contained in:
parent
83363044f3
commit
19f1b85c1f
@ -165,7 +165,8 @@ procedure TSizeConstraints.SetMaxWidth(Value: TConstraintSize);
|
||||
begin
|
||||
if Value <> FMaxWidth then begin
|
||||
FMaxWidth:= Value;
|
||||
if (FMinWidth > 0) and (FMaxWidth < FMinWidth) then FMinWidth:= FMaxWidth;
|
||||
if (FMinWidth > 0) and (FMaxWidth>0) and (FMaxWidth < FMinWidth) then
|
||||
FMinWidth:= FMaxWidth;
|
||||
Change;
|
||||
end;
|
||||
end;
|
||||
@ -181,7 +182,8 @@ procedure TSizeConstraints.SetMaxHeight(Value: TConstraintSize);
|
||||
begin
|
||||
if Value <> FMaxHeight then begin
|
||||
FMaxHeight:= Value;
|
||||
if (FMinHeight > 0) and (FMaxHeight < FMinHeight) then FMinHeight:= FMaxHeight;
|
||||
if (FMinHeight > 0) and (FMaxHeight>0) and (FMaxHeight < FMinHeight) then
|
||||
FMinHeight:= FMaxHeight;
|
||||
Change;
|
||||
end;
|
||||
end;
|
||||
|
Loading…
Reference in New Issue
Block a user