FindDialog: fix reading actual position the finddialogform for Left and Top. Issue #0030668.

git-svn-id: trunk@53061 -
This commit is contained in:
bart 2016-09-30 20:28:59 +00:00
parent e01bc2c59e
commit 27ba944bdb

View File

@ -423,16 +423,20 @@ end;
function TFindDialog.GetLeft: Integer;
begin
if Assigned(FFindForm) then
FFormLeft := FFindForm.Left;
Result:=FFormLeft;
end;
function TFindDialog.GetPosition: TPoint;
begin
Result:=Point(FFormLeft, FFormTop);
Result:=Point(GetLeft, GetTop);
end;
function TFindDialog.GetTop: Integer;
begin
if Assigned(FFindForm) then
FFormTop := FFindForm.Top;
Result:=FFormTop;
end;
@ -464,8 +468,8 @@ end;
procedure TFindDialog.SetPosition(const AValue: TPoint);
begin
if (FFormLeft <> AValue.x) then Left := AValue.x;
If (FFormTop <> AValue.y) then Top := AValue.y;
if (GetLeft <> AValue.x) then Left := AValue.x;
If (GetTop <> AValue.y) then Top := AValue.y;
end;
procedure TFindDialog.SetTop(const AValue: Integer);