mirror of https://gitlab.com/basile.b/dexed.git
prevent to retrieve the IProcInputHandler service each time required
This commit is contained in:
parent
e6204b49e1
commit
0abd58637b
|
@ -395,6 +395,7 @@ type
|
||||||
fDoc: TDexedMemo;
|
fDoc: TDexedMemo;
|
||||||
fFirstTimeRun: boolean;
|
fFirstTimeRun: boolean;
|
||||||
fMultidoc: IMultiDocHandler;
|
fMultidoc: IMultiDocHandler;
|
||||||
|
fProcInputHandler: IProcInputHandler;
|
||||||
fScCollectCount: Integer;
|
fScCollectCount: Integer;
|
||||||
fUpdateCount: NativeInt;
|
fUpdateCount: NativeInt;
|
||||||
fProject: ICommonProject;
|
fProject: ICommonProject;
|
||||||
|
@ -1302,6 +1303,7 @@ begin
|
||||||
mainMenu.Items.Remove(mnuItemHelp);
|
mainMenu.Items.Remove(mnuItemHelp);
|
||||||
mainMenu.Items.Add(mnuItemHelp);
|
mainMenu.Items.Add(mnuItemHelp);
|
||||||
|
|
||||||
|
fProcInputHandler := getprocInputHandler;
|
||||||
fInitialized := true;
|
fInitialized := true;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
@ -1954,21 +1956,21 @@ end;
|
||||||
|
|
||||||
procedure TMainForm.FreeRunnableProc;
|
procedure TMainForm.FreeRunnableProc;
|
||||||
var
|
var
|
||||||
fname: string;
|
f: string;
|
||||||
begin
|
begin
|
||||||
if fRunProc.isNil then
|
if fRunProc.isNil then
|
||||||
exit;
|
exit;
|
||||||
|
|
||||||
fname := fRunProc.Executable;
|
f := fRunProc.Executable;
|
||||||
if getprocInputHandler.process = fRunProc then
|
if fProcInputHandler.process = fRunProc then
|
||||||
begin
|
begin
|
||||||
getMessageDisplay.message('the execution of a runnable module ' +
|
getMessageDisplay.message('the execution of a runnable module ' +
|
||||||
'has been implicitly aborted', fDoc, amcEdit, amkWarn);
|
'has been implicitly aborted', fDoc, amcEdit, amkWarn);
|
||||||
getprocInputHandler.addProcess(nil);
|
fProcInputHandler.addProcess(nil);
|
||||||
end;
|
end;
|
||||||
killProcess(fRunProc);
|
killProcess(fRunProc);
|
||||||
if fname.fileExists and (fname.extractFilePath = GetTempDir(false)) then
|
if f.fileExists and (f.extractFilePath = GetTempDir(false)) then
|
||||||
sysutils.DeleteFile(fname);
|
sysutils.DeleteFile(f);
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TMainForm.SaveLastDocsAndProj;
|
procedure TMainForm.SaveLastDocsAndProj;
|
||||||
|
|
Loading…
Reference in New Issue