Skip to content
This repository was archived by the owner on Sep 26, 2021. It is now read-only.

Commit 0be4f32

Browse files
committed
Do not allow user to remove checkboxes that are required for install to work
Signed-off-by: Jeffrey Morgan <[email protected]>
1 parent 7ef9d39 commit 0be4f32

File tree

2 files changed

+11
-10
lines changed

2 files changed

+11
-10
lines changed

osx/mpkg/Distribution

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
<line choice="choiceVBox"/>
1414
<line choice="choiceBoot2DockerISO"/>
1515
</choices-outline>
16-
<choice id="choiceDockerCLI" title="choiceDockerCLI_title" description="choiceDockerCLI_msg" start_selected="true" start_visible="true">
16+
<choice id="choiceDockerCLI" title="choiceDockerCLI_title" description="choiceDockerCLI_msg" start_enabled="false" start_selected="true" start_visible="true">
1717
<pkg-ref id="io.docker.pkg.docker"/>
1818
</choice>
1919
<choice id="choiceDockerComposeCLI" title="choiceDockerComposeCLI_title" description="choiceDockerComposeCLI_msg" start_selected="true" start_enabled="true" start_visible="true">
@@ -73,7 +73,7 @@
7373
<pkg-ref id="io.docker.pkg.kitematicapp">
7474
<bundle-version/>
7575
</pkg-ref>
76-
<choice id="choiceDockerMachineCLI" title="choiceDockerMachineCLI_title" description="choiceDockerMachineCLI_msg" start_selected="true" start_enabled="true" start_visible="true">
76+
<choice id="choiceDockerMachineCLI" title="choiceDockerMachineCLI_title" description="choiceDockerMachineCLI_msg" start_enabled="false" start_selected="true" start_visible="true">
7777
<pkg-ref id="io.docker.pkg.dockermachine"/>
7878
</choice>
7979
<pkg-ref id="io.docker.pkg.dockermachine" auth="Root" version="%DOCKERMACHINE_VERSION%" installKBytes="%DOCKERMACHINE_INSTALL_KBYTES%">#dockermachine.pkg</pkg-ref>
@@ -148,7 +148,7 @@
148148
{
149149
try {
150150
vboxplist = system.files.plistAtPath('/Applications/VirtualBox.app/Contents/Info.plist');
151-
if (!vboxplist || !vboxplist.CFBundleVersion || (vboxplist.CFBundleVersion === '5.0.2' && system.version.ProductVersion !== '10.11') || system.compareVersions(vboxplist.CFBundleVersion, '%VBOX_VERSION%') === -1) {
151+
if (!vboxplist || !vboxplist.CFBundleVersion || system.compareVersions(vboxplist.CFBundleVersion, '%VBOX_VERSION%') === -1) {
152152
return true;
153153
}
154154

windows/Toolbox.iss

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ Name: "english"; MessagesFile: "compiler:Default.isl"
4343

4444
[Types]
4545
Name: "full"; Description: "Full installation"
46-
Name: "upgrade"; Description: "Upgrade Docker Toolbox only"
4746
Name: "custom"; Description: "Custom installation"; Flags: iscustom
4847

4948
[Run]
@@ -54,11 +53,11 @@ Name: desktopicon; Description: "{cm:CreateDesktopIcon}"
5453
Name: modifypath; Description: "Add docker.exe & docker-machine.exe to &PATH"
5554

5655
[Components]
57-
Name: "Docker"; Description: "Docker Client for Windows" ; Types: full upgrade
58-
Name: "DockerMachine"; Description: "Docker Machine for Windows" ; Types: full upgrade
59-
Name: "Kitematic"; Description: "Kitematic for Windows (Alpha)" ; Types: full upgrade
60-
Name: "VirtualBox"; Description: "VirtualBox"; Types: full; Flags: disablenouninstallwarning
61-
Name: "Git"; Description: "Git for Windows"; Types: full; Flags: disablenouninstallwarning
56+
Name: "Docker"; Description: "Docker Client for Windows" ; Types: full custom; Flags: fixed
57+
Name: "DockerMachine"; Description: "Docker Machine for Windows" ; Types: full custom; Flags: fixed
58+
Name: "VirtualBox"; Description: "VirtualBox"; Types: full custom; Flags: disablenouninstallwarning
59+
Name: "Kitematic"; Description: "Kitematic for Windows (Alpha)" ; Types: full custom
60+
Name: "Git"; Description: "Git for Windows"; Types: full custom; Flags: disablenouninstallwarning
6261

6362
[Files]
6463
Source: ".\docker-quickstart-terminal.ico"; DestDir: "{app}"; Flags: ignoreversion
@@ -255,8 +254,10 @@ begin
255254
'For further information, please see the {#MyAppName} installation documentation link.'
256255
257256
// Don't do this until we can compare versions
258-
// Wizardform.ComponentsList.Checked[3] := NeedToInstallVirtualBox();
257+
// Wizardform.ComponentsList.Checked[2] := NeedToInstallVirtualBox();
258+
Wizardform.ComponentsList.ItemEnabled[2] := not NeedToInstallVirtualBox();
259259
Wizardform.ComponentsList.Checked[4] := NeedToInstallGit();
260+
Wizardform.ComponentsList.ItemEnabled[4] := not NeedToInstallGit();
260261
end;
261262
262263
function InitializeSetup(): boolean;

0 commit comments

Comments
 (0)