Commit 406ae30f authored by Bart B's avatar Bart B 🐞
Browse files

TFindDialog/TReplaceDialog: show dialog poScreenCenter in IDE; fix erratic...

TFindDialog/TReplaceDialog: show dialog poScreenCenter in IDE; fix erratic behaviour of TReplaceDialog in IDE (wrong parent). Issue #34297.

git-svn-id: trunk@59083 -
parent ac8ef42f
......@@ -579,6 +579,11 @@ end;
procedure TFindDialog.CalcPosition(aForm:Tform);
begin
//debugln(['TFindDialog.CalcPosition: Left=',Left,', Top=',Top,', Position=',dbgs(position),', FFormLeft=',FFormLeft,', FFormTop=',FFormTop]);
if (csDesigning in ComponentState) then
begin
aForm.Position := poScreenCenter;
Exit;
end;
if (FFormLeft < 0) and (FFormTop < 0) then
begin
aForm.Position := poMainFormCenter;
......
......@@ -516,7 +516,7 @@ end;
function TReplaceDialog.CreateForm: TForm;
begin
Result := TReplaceDialogForm.CreateNew(Self,Options);
Result := TReplaceDialogForm.CreateNew(nil,Options);
with TReplaceDialogForm(Result) do
begin
FindMoreButton.Caption := rsFindMore;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment