Create Windows installer #53
This commit is contained in:
@@ -54,19 +54,6 @@ begin
|
|||||||
Result := S;
|
Result := S;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function CheckAddPath(NewPath: string): Boolean;
|
|
||||||
var
|
|
||||||
OldPath: string;
|
|
||||||
begin
|
|
||||||
if not RegQueryStringValue(HKLM,
|
|
||||||
'SYSTEM\CurrentControlSet\Control\Session Manager\Environment',
|
|
||||||
'Path', OldPath)
|
|
||||||
then
|
|
||||||
OldPath := '';
|
|
||||||
|
|
||||||
Result := Pos(LowerCase(NewPath), LowerCase(OldPath)) = 0;
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure AddAppToPath();
|
procedure AddAppToPath();
|
||||||
var
|
var
|
||||||
OldPath, NewPath, FinalPath: string;
|
OldPath, NewPath, FinalPath: string;
|
||||||
@@ -92,14 +79,6 @@ begin
|
|||||||
end;
|
end;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
procedure CurStepChanged(CurStep: TSetupStep);
|
|
||||||
begin
|
|
||||||
if CurStep = ssPostInstall then
|
|
||||||
begin
|
|
||||||
AddAppToPath();
|
|
||||||
end;
|
|
||||||
end;
|
|
||||||
|
|
||||||
procedure RemoveAppFromPath();
|
procedure RemoveAppFromPath();
|
||||||
var
|
var
|
||||||
OldPath, NewPath, Token, Remainder, FinalPath: string;
|
OldPath, NewPath, Token, Remainder, FinalPath: string;
|
||||||
@@ -149,6 +128,14 @@ begin
|
|||||||
RefreshEnvironment();
|
RefreshEnvironment();
|
||||||
end;
|
end;
|
||||||
|
|
||||||
|
procedure CurStepChanged(CurStep: TSetupStep);
|
||||||
|
begin
|
||||||
|
if CurStep = ssPostInstall then
|
||||||
|
begin
|
||||||
|
AddAppToPath();
|
||||||
|
end;
|
||||||
|
end;
|
||||||
|
|
||||||
procedure DeinitializeUninstall();
|
procedure DeinitializeUninstall();
|
||||||
begin
|
begin
|
||||||
RemoveAppFromPath();
|
RemoveAppFromPath();
|
||||||
|
Reference in New Issue
Block a user