Skip to content
This repository was archived by the owner on May 1, 2024. It is now read-only.

Commit cfe9265

Browse files
committed
Disables entries which don't match compat. mask
1 parent 9a454da commit cfe9265

File tree

1 file changed

+9
-4
lines changed

1 file changed

+9
-4
lines changed

ElixirWeb.iss

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515
;
1616
; "Elixir" and the Elixir logo are copyright (c) 2012 Plataformatec.
1717

18+
#define COMPAT_MASK 1
1819
#include <idp.iss>
1920

2021
[Setup]
@@ -103,7 +104,7 @@ procedure ParseReleasesCSV;
103104
var
104105
ReleaseStrings: TArrayOfString;
105106
NumReleases: Integer;
106-
i: Integer;
107+
i: Integer;
107108
LineValues: TStringList;
108109
begin
109110
LoadStringsFromFile(ExpandConstant('{tmp}\releases.csv'), ReleaseStrings);
@@ -122,6 +123,7 @@ end;
122123
procedure PopulateListOfReleases();
123124
var
124125
LatestRelease: Boolean;
126+
MatchesCompatMask: Boolean;
125127
VersionLabel: String;
126128
i: Integer;
127129
begin
@@ -130,9 +132,12 @@ begin
130132
VersionLabel := 'Version ' + ElixirReleases[i].Version;
131133
if LatestRelease then
132134
VersionLabel := VersionLabel + ' (Latest)';
133-
134-
PSelectVerListBox.AddRadioButton(VersionLabel, ElixirReleases[i].ReleaseType, 0, LatestRelease, True, nil);
135-
LatestRelease := False;
135+
136+
MatchesCompatMask := (ElixirReleases[i].CompatMask = {#COMPAT_MASK});
137+
PSelectVerListBox.AddRadioButton(VersionLabel, ElixirReleases[i].ReleaseType, 0, LatestRelease, MatchesCompatMask, nil);
138+
139+
if MatchesCompatMask then
140+
LatestRelease := False;
136141
end;
137142
end;
138143

0 commit comments

Comments
 (0)