mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-21 09:59:32 +02:00
IDE: restore window layout only once
git-svn-id: trunk@26113 -
This commit is contained in:
parent
b86bdbe6bf
commit
73e5c20887
@ -1140,10 +1140,7 @@ begin
|
||||
end;
|
||||
|
||||
procedure TAnchorDockLayoutTreeNode.CheckConsistency;
|
||||
{ ToDo: check that all childs are connected
|
||||
check for topological sort
|
||||
check for not overlapping (the bounds can overlap because of constraints)
|
||||
}
|
||||
{ ToDo: check for topological sort }
|
||||
|
||||
procedure CheckCornerIsUnique(Side1: TAnchorKind; Side1AnchorName: string;
|
||||
Side2: TAnchorKind; Side2AnchorName: string);
|
||||
|
@ -173,6 +173,7 @@ type
|
||||
|
||||
TSimpleWindowLayout = class(TComponent)
|
||||
private
|
||||
FApplied: boolean;
|
||||
FFormCaption: string;
|
||||
FVisible: boolean;
|
||||
fWindowPlacement: TIDEWindowPlacement;
|
||||
@ -225,6 +226,7 @@ type
|
||||
read fWindowState write SetWindowState;
|
||||
property Form: TCustomForm read fForm write SetForm;
|
||||
property Visible: boolean read FVisible write SetVisible;
|
||||
property Applied: boolean read FApplied write FApplied;
|
||||
end;
|
||||
|
||||
{ TSimpleWindowLayoutList }
|
||||
@ -593,6 +595,7 @@ end;
|
||||
procedure TSimpleWindowLayout.Assign(Layout: TSimpleWindowLayout);
|
||||
begin
|
||||
Clear;
|
||||
FApplied:=Layout.Applied;
|
||||
Form:=Layout.Form;
|
||||
fWindowPlacement:=Layout.fWindowPlacement;
|
||||
fLeft:=Layout.fLeft;
|
||||
@ -741,6 +744,9 @@ begin
|
||||
if ALayout<>nil then
|
||||
begin
|
||||
ALayout.Form:=AForm;
|
||||
if ALayout.Applied then exit;
|
||||
ALayout.Applied:=true;
|
||||
debugln(['TSimpleWindowLayoutList.ApplyAndShow restore']);
|
||||
|
||||
WindowType:=NonModalIDEFormIDToEnum(ALayout.FormID);
|
||||
SubIndex := -1;
|
||||
@ -790,7 +796,6 @@ begin
|
||||
exit;
|
||||
end;
|
||||
end;
|
||||
|
||||
end;
|
||||
|
||||
// no layout found => use default
|
||||
|
Loading…
Reference in New Issue
Block a user