mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 23:09:16 +02:00
anchordocking: resize after redock custom dock site
git-svn-id: trunk@26025 -
This commit is contained in:
parent
97c419e8ac
commit
3cf422d211
@ -1939,18 +1939,34 @@ procedure TAnchorDockHostSite.RemoveControlFromLayout(AControl: TControl);
|
||||
and (Parent.Parent=nil))
|
||||
then begin
|
||||
// shrink this site and the parent (which is a custom dock site)
|
||||
NewParentBounds:=Parent.BoundsRect;
|
||||
case Align of
|
||||
alTop:
|
||||
begin
|
||||
NewParentBounds:=Parent.BoundsRect;
|
||||
// ToDo Height:=OnlySiteLeft.Height;
|
||||
|
||||
Parent.BoundsRect:=NewParentBounds;
|
||||
inc(NewParentBounds.Top,Height-OnlySiteLeft.Height);
|
||||
Width:=Parent.ClientWidth;
|
||||
Height:=OnlySiteLeft.Height;
|
||||
end;
|
||||
alBottom:
|
||||
begin
|
||||
dec(NewParentBounds.Bottom,Height-OnlySiteLeft.Height);
|
||||
Width:=Parent.ClientWidth;
|
||||
Height:=OnlySiteLeft.Height;
|
||||
end;
|
||||
alLeft:
|
||||
begin
|
||||
inc(NewParentBounds.Left,Width-OnlySiteLeft.Width);
|
||||
Width:=OnlySiteLeft.Width;
|
||||
Height:=Parent.ClientHeight;
|
||||
end;
|
||||
alRight:
|
||||
begin
|
||||
dec(NewParentBounds.Right,Width-OnlySiteLeft.Width);
|
||||
Width:=OnlySiteLeft.Width;
|
||||
Height:=Parent.ClientHeight;
|
||||
end;
|
||||
alBottom: ;
|
||||
alLeft: ;
|
||||
alRight: ;
|
||||
end;
|
||||
Parent.BoundsRect:=NewParentBounds;
|
||||
end;
|
||||
|
||||
// change type
|
||||
|
Loading…
Reference in New Issue
Block a user