mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-18 15:29:32 +02:00
DockedFormEditor: Fixed flickering at anchoring control
git-svn-id: trunk@64624 -
This commit is contained in:
parent
0c46287ea3
commit
89deb31d9e
components/dockedformeditor/source
@ -413,7 +413,8 @@ end;
|
||||
|
||||
procedure TAnchorDesigner.CreateAnchorGrips;
|
||||
begin
|
||||
FAnchorGrips := TAnchorGrips.Create(FBackGround);
|
||||
FAnchorGrips := TAnchorGrips.Create;
|
||||
FAnchorGrips.Parent := Parent;
|
||||
FAnchorGrips.BackGround := FBackGround;
|
||||
FAnchorGrips.OnMouseDown := @AnchorGripMouseDown;
|
||||
FAnchorGrips.OnMouseMove := @AnchorGripMouseMove;
|
||||
@ -949,8 +950,8 @@ end;
|
||||
procedure TAnchorDesigner.SetParent(AValue: TWinControl);
|
||||
begin
|
||||
inherited SetParent(AValue);
|
||||
if Assigned(FBackGround) then
|
||||
FBackGround.Parent := Parent;
|
||||
if Assigned(FBackGround) then FBackGround.Parent := Parent;
|
||||
if Assigned(FAnchorGrips) then FAnchorGrips.Parent := Parent;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
@ -58,9 +58,10 @@ type
|
||||
procedure SetOnMouseDown(AValue: TMouseEvent);
|
||||
procedure SetOnMouseMove(AValue: TMouseMoveEvent);
|
||||
procedure SetOnMouseUp(AValue: TMouseEvent);
|
||||
procedure SetParent(AValue: TWinControl);
|
||||
procedure SetPopupMenu(AValue: TPopupMenu);
|
||||
public
|
||||
constructor Create(AParent: TWinControl);
|
||||
constructor Create;
|
||||
destructor Destroy; override;
|
||||
procedure AdjustGrips(AControl: TControl);
|
||||
procedure BringToFront;
|
||||
@ -80,6 +81,7 @@ type
|
||||
property OnMouseDown: TMouseEvent read FOnMouseDown write SetOnMouseDown;
|
||||
property OnMouseMove: TMouseMoveEvent read FOnMouseMove write SetOnMouseMove;
|
||||
property OnMouseUp: TMouseEvent read FOnMouseUp write SetOnMouseUp;
|
||||
property Parent: TWinControl read FParent write SetParent;
|
||||
property PopupMenu: TPopupMenu read GetPopupMenu write SetPopupMenu;
|
||||
end;
|
||||
|
||||
@ -176,6 +178,16 @@ begin
|
||||
FGrip[i].OnMouseUp := AValue;
|
||||
end;
|
||||
|
||||
procedure TAnchorGrips.SetParent(AValue: TWinControl);
|
||||
var
|
||||
i: Integer;
|
||||
begin
|
||||
if FParent = AValue then Exit;
|
||||
FParent := AValue;
|
||||
for i := 0 to 7 do
|
||||
FGrip[i].Parent := AValue;
|
||||
end;
|
||||
|
||||
procedure TAnchorGrips.SetPopupMenu(AValue: TPopupMenu);
|
||||
var
|
||||
i: Integer;
|
||||
@ -185,11 +197,10 @@ begin
|
||||
FGrip[i].PopupMenu := AValue;
|
||||
end;
|
||||
|
||||
constructor TAnchorGrips.Create(AParent: TWinControl);
|
||||
constructor TAnchorGrips.Create;
|
||||
var
|
||||
i: Integer;
|
||||
begin
|
||||
FParent := AParent;
|
||||
FGripSize := ScaleX(GRIP_SIZE, 96);
|
||||
|
||||
for i := 0 to 7 do
|
||||
|
@ -336,7 +336,6 @@ end;
|
||||
procedure TSourceEditorWindows.RefreshAllPageControls;
|
||||
var
|
||||
LWindow: TSourceEditorWindow;
|
||||
LPageCtrl: TModulePageControl;
|
||||
LSourceEditorPageControl: TSourceEditorPageControl;
|
||||
begin
|
||||
for LWindow in SourceEditorWindows do
|
||||
|
Loading…
Reference in New Issue
Block a user