Packager: One more improvement for not closing package editor while compiling.

git-svn-id: trunk@62948 -
This commit is contained in:
juha 2020-04-11 16:27:17 +00:00
parent c6a922e9c2
commit f1add4d1d5

View File

@ -3401,14 +3401,17 @@ begin
else
LazPackage.Modified:=false; // clear modified flag, so that it will be closed
end;
if (Result=mrOK) and not MainIDE.IDEIsClosing then
if not MainIDE.IDEIsClosing then
begin
EnvironmentOptions.LastOpenPackages.Remove(LazPackage.Filename);
MainIDE.SaveEnvironment;
if FCompiling then begin
DebugLn(['TPackageEditorForm.CanCloseEditor: ', Caption, ' compiling, do not close.']);
Result:=mrCancel;
end;
if Result=mrOK then
begin
EnvironmentOptions.LastOpenPackages.Remove(LazPackage.Filename);
MainIDE.SaveEnvironment;
end;
end;
end;
//debugln(['TPackageEditorForm.CanCloseEditor Result=',dbgs(Result),' ',Caption]);