Merge branch 'bugfix/IDFGH-2036_2' into 'master'

Tools Setup: fixed WD task checkbox disabling

Closes IDFGH-2036

See merge request espressif/esp-idf!7204
This commit is contained in:
Ivan Grokhotkov 2020-01-09 22:39:48 +08:00
commit 1fd7f21d8c
2 changed files with 13 additions and 2 deletions

View File

@ -302,7 +302,16 @@ begin
Log('CheckWinDefenderAvailable: ' + szHasWD);
WizardForm.TasksList.ItemEnabled[1] := bHasWD;
WizardForm.TasksList.Checked[1] := bHasWD;
{ WD registration checkbox is identified by 'Windows Defender' substring anywhere in its caption.
Please, keep this in mind when making changes }
for x:=0 to (WizardForm.TasksList.Items.Count-1) do
begin
if Pos('Windows Defender', WizardForm.TasksList.ItemCaption[x]) > 0 then
begin
WizardForm.TasksList.ItemEnabled[x] := bHasWD;
WizardForm.TasksList.Checked[x] := bHasWD;
break;
end;
end;
end;
end;

View File

@ -79,6 +79,8 @@ Type: files; Name: "{autodesktop}\{#IDFCmdExeShortcutFile}"
[Tasks]
Name: createlnk; Description: "Create Start Menu shortcut for the ESP-IDF Tools Command Prompt";
Name: createdsk; Description: "Create Desktop shortcut for the ESP-IDF Tools Command Prompt";
; WD registration checkbox is identified by 'Windows Defender' substring anywhere in its caption, not by the position index in WizardForm.TasksList.Items
; Please, keep this in mind when making changes to the item's description - WD checkbox is to be disabled on systems without the Windows Defender installed
Name: wdexcl; Description: "Register the ESP-IDF Tools executables as Windows Defender exclusions (improves compilation speed, requires elevation)";
[Run]