[#63] added publisher info and stubbed in license agreement

Former-commit-id: af9707b4cc264e368eea50bf514818c4f49f688c

; -- Example1.iss --
; Demonstrates copying 3 files and creating an icon.

; SEE THE DOCUMENTATION FOR DETAILS ON CREATING .ISS SCRIPT FILES!

[Setup]
AppPublisher=Adobe Inc.
AppPublisherURL=https://www.adobe.com/
AppName=PhoneGap Desktop
AppVersion=0.1.1
DefaultDirName={pf}\My Program\PhoneGap Desktop
DefaultGroupName=My Program
UninstallDisplayIcon={app}\MyProg.exe
Compression=lzma2
SolidCompression=yes
OutputDir=userdocs:Inno Setup Examples Output
; LicenseFile=license.text

[Files]
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\PhoneGap.exe"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\nw.pak"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\libGLESv2.dll"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\libEGL.dll"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\icudtl.dat"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\ffmpegsumo.dll"; DestDir: "{app}"

[Icons]
;Name: "{group}\My Program"; Filename: "{app}\MyProg.exe"

[Code]
// Utility functions for Inno Setup
//   used to add/remove programs from the windows firewall rules
// Code originally from http://news.jrsoftware.org/news/innosetup/msg43799.html

const
  NET_FW_SCOPE_ALL = 0;
  NET_FW_IP_VERSION_ANY = 2;

procedure SetFirewallException(AppName,FileName:string);
var
  FirewallObject: Variant;
  FirewallManager: Variant;
  FirewallProfile: Variant;
begin
  try
    FirewallObject := CreateOleObject('HNetCfg.FwAuthorizedApplication');
    FirewallObject.ProcessImageFileName := FileName;
    FirewallObject.Name := AppName;
    FirewallObject.Scope := NET_FW_SCOPE_ALL;
    FirewallObject.IpVersion := NET_FW_IP_VERSION_ANY;
    FirewallObject.Enabled := True;
    FirewallManager := CreateOleObject('HNetCfg.FwMgr');
    FirewallProfile := FirewallManager.LocalPolicy.CurrentProfile;
    FirewallProfile.AuthorizedApplications.Add(FirewallObject);
  except
  end;
end;

procedure RemoveFirewallException( FileName:string );
var
  FirewallManager: Variant;
  FirewallProfile: Variant;
begin
  try
    FirewallManager := CreateOleObject('HNetCfg.FwMgr');
    FirewallProfile := FirewallManager.LocalPolicy.CurrentProfile;
    FireWallProfile.AuthorizedApplications.Remove(FileName);
  except
  end;
end;

procedure CurStepChanged(CurStep: TSetupStep);
begin
  if CurStep=ssPostInstall then
     SetFirewallException('My Server', ExpandConstant('{app}')+'\TCPServer.exe');
end;

procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
  if CurUninstallStep=usPostUninstall then
     RemoveFirewallException(ExpandConstant('{app}')+'\TCPServer.exe');
end;

; -- Example1.iss --
; Demonstrates copying 3 files and creating an icon.

; SEE THE DOCUMENTATION FOR DETAILS ON CREATING .ISS SCRIPT FILES!

[Setup]
AppName=PhoneGap Desktop
AppVersion=0.1.1
DefaultDirName={pf}\My Program\PhoneGap Desktop
DefaultGroupName=My Program
UninstallDisplayIcon={app}\MyProg.exe
Compression=lzma2
SolidCompression=yes
OutputDir=userdocs:Inno Setup Examples Output

[Files]
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\PhoneGap.exe"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\nw.pak"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\libGLESv2.dll"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\libEGL.dll"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\icudtl.dat"; DestDir: "{app}"
Source: "C:\Users\herm\Documents\HermWong\phonegap-gui\build\PhoneGap\win\ffmpegsumo.dll"; DestDir: "{app}"

[Icons]
;Name: "{group}\My Program"; Filename: "{app}\MyProg.exe"

[Code]
// Utility functions for Inno Setup
//   used to add/remove programs from the windows firewall rules
// Code originally from http://news.jrsoftware.org/news/innosetup/msg43799.html

const
  NET_FW_SCOPE_ALL = 0;
  NET_FW_IP_VERSION_ANY = 2;

procedure SetFirewallException(AppName,FileName:string);
var
  FirewallObject: Variant;
  FirewallManager: Variant;
  FirewallProfile: Variant;
begin
  try
    FirewallObject := CreateOleObject('HNetCfg.FwAuthorizedApplication');
    FirewallObject.ProcessImageFileName := FileName;
    FirewallObject.Name := AppName;
    FirewallObject.Scope := NET_FW_SCOPE_ALL;
    FirewallObject.IpVersion := NET_FW_IP_VERSION_ANY;
    FirewallObject.Enabled := True;
    FirewallManager := CreateOleObject('HNetCfg.FwMgr');
    FirewallProfile := FirewallManager.LocalPolicy.CurrentProfile;
    FirewallProfile.AuthorizedApplications.Add(FirewallObject);
  except
  end;
end;

procedure RemoveFirewallException( FileName:string );
var
  FirewallManager: Variant;
  FirewallProfile: Variant;
begin
  try
    FirewallManager := CreateOleObject('HNetCfg.FwMgr');
    FirewallProfile := FirewallManager.LocalPolicy.CurrentProfile;
    FireWallProfile.AuthorizedApplications.Remove(FileName);
  except
  end;
end;

procedure CurStepChanged(CurStep: TSetupStep);
begin
  if CurStep=ssPostInstall then
     SetFirewallException('My Server', ExpandConstant('{app}')+'\TCPServer.exe');
end;

procedure CurUninstallStepChanged(CurUninstallStep: TUninstallStep);
begin
  if CurUninstallStep=usPostUninstall then
     RemoveFirewallException(ExpandConstant('{app}')+'\TCPServer.exe');
end;


Win installer: Add functions that can detect installed version

No functional changes.
InitializeSetup() (currently commented out) can inform the user
about the version differences and uninstall the old version before
installing the new one.

Signed-off-by: Dan Nechita <2f664a27dbc3ee2034ed9e950b3808890cb5416a@analog.com>

#define AppName "Pixelpulse2"
#define AppVersion "0.90"
#define AppPublisher "Analog Devices, Inc."
#define AppURL "http://www.analog.com"
#define AppExeName "Pixelpulse2.exe"

[Setup]
AppId={{258C031E-98C7-4609-9122-65A4D36274AF}
AppName={#AppName}
AppVersion={#AppVersion}
AppPublisher={#AppPublisher}
AppPublisherURL={#AppURL}
AppSupportURL={#AppURL}
AppUpdatesURL={#AppURL}
DefaultDirName={pf}\Analog Devices\{#AppName}
DefaultGroupName=Analog Devices\{#AppName}
OutputDir="C:\"
OutputBaseFilename=Pixelpulse2_win_setup
UninstallDisplayIcon={app}\{#AppExeName}
Compression=lzma
SolidCompression=yes

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"
Name: "brazilianportuguese"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
Name: "catalan"; MessagesFile: "compiler:Languages\Catalan.isl"
Name: "corsican"; MessagesFile: "compiler:Languages\Corsican.isl"
Name: "czech"; MessagesFile: "compiler:Languages\Czech.isl"
Name: "danish"; MessagesFile: "compiler:Languages\Danish.isl"
Name: "dutch"; MessagesFile: "compiler:Languages\Dutch.isl"
Name: "finnish"; MessagesFile: "compiler:Languages\Finnish.isl"
Name: "french"; MessagesFile: "compiler:Languages\French.isl"
Name: "german"; MessagesFile: "compiler:Languages\German.isl"
Name: "greek"; MessagesFile: "compiler:Languages\Greek.isl"
Name: "hebrew"; MessagesFile: "compiler:Languages\Hebrew.isl"
Name: "hungarian"; MessagesFile: "compiler:Languages\Hungarian.isl"
Name: "italian"; MessagesFile: "compiler:Languages\Italian.isl"
Name: "japanese"; MessagesFile: "compiler:Languages\Japanese.isl"
Name: "norwegian"; MessagesFile: "compiler:Languages\Norwegian.isl"
Name: "polish"; MessagesFile: "compiler:Languages\Polish.isl"
Name: "portuguese"; MessagesFile: "compiler:Languages\Portuguese.isl"
Name: "russian"; MessagesFile: "compiler:Languages\Russian.isl"
Name: "scottishgaelic"; MessagesFile: "compiler:Languages\ScottishGaelic.isl"
Name: "serbiancyrillic"; MessagesFile: "compiler:Languages\SerbianCyrillic.isl"
Name: "serbianlatin"; MessagesFile: "compiler:Languages\SerbianLatin.isl"
Name: "slovenian"; MessagesFile: "compiler:Languages\Slovenian.isl"
Name: "spanish"; MessagesFile: "compiler:Languages\Spanish.isl"
Name: "turkish"; MessagesFile: "compiler:Languages\Turkish.isl"
Name: "ukrainian"; MessagesFile: "compiler:Languages\Ukrainian.isl"

[Tasks]
Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"
; Only allow driver installs for Windows 7 (version 6.2 maps to Windows 8).
Name: drivers; Description: Install WinUSB drivers for the M1K; OnlyBelowVersion: 6.2

[Files]
Source: "c:\projects\pixelpulse2\release\pixelpulse2.exe"; DestDir: "{app}"
Source: "c:\projects\pixelpulse2\distrib\*"; DestDir: "{app}"; Flags: recursesubdirs createallsubdirs
Source: "C:\WinDDK\7600.16385.1\redist\DIFx\dpinst\EngMui\x86\dpinst.exe"; DestDir: "{app}\drivers"; Tasks: drivers; Check: not IsWin64
Source: "C:\WinDDK\7600.16385.1\redist\DIFx\dpinst\EngMui\amd64\dpinst.exe"; DestDir: "{app}\drivers"; Tasks: drivers; Check: IsWin64

[Icons]
Name: "{group}\{#AppName}"; Filename: "{app}\{#AppExeName}"
Name: "{group}\{cm:UninstallProgram,{#AppName}}"; Filename: "{uninstallexe}"
Name: "{commondesktop}\{#AppName}"; Filename: "{app}\{#AppExeName}"; Tasks: desktopicon

[Run]
Filename: "{app}\{#AppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(AppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent unchecked
Filename: {app}\pp2trayer.exe; Description: "Launch Pixelpulse2 Trayer"; Flags: nowait postinstall skipifsilent
Filename: "{app}\drivers\dpinst.exe"; Parameters: "/path ""{app}\drivers"""; Flags: waituntilterminated; Tasks: drivers

[UninstallRun]
Filename: "{cmd}"; Parameters: "/C""taskkill /im pp2trayer.exe /f /t"; Flags: runhidden

[Registry]
; Make Pixelpulse2 Trayer run every time Windows boots
Root: HKLM; Subkey: "SOFTWARE\Microsoft\Windows\CurrentVersion\Run"; ValueType: string; ValueName: "Pixelpulse2Trayer"; ValueData: """{app}\pp2trayer.exe"""; Flags: uninsdeletevalue

; Functions GetNumber(), CompareInner(), CompareVersion() and InitializeSetup() can be used to detect
; differences between the version being installed and the version that might be already installed.
[Code]
function GetNumber(var temp: String): Integer;
var
  part: String;
  pos1: Integer;
begin
  if Length(temp) = 0 then
  begin
    Result := -1;
    Exit;
  end;
    pos1 := Pos('.', temp);
    if (pos1 = 0) then
    begin
      Result := StrToInt(temp);
    temp := '';
    end
    else
    begin
    part := Copy(temp, 1, pos1 - 1);
      temp := Copy(temp, pos1 + 1, Length(temp));
      Result := StrToInt(part);
    end;
end;

function CompareInner(var temp1, temp2: String): Integer;
var
  num1, num2: Integer;
begin
    num1 := GetNumber(temp1);
  num2 := GetNumber(temp2);
  if (num1 = -1) or (num2 = -1) then
  begin
    Result := 0;
    Exit;
  end;
      if (num1 > num2) then
      begin
        Result := 1;
      end
      else if (num1 < num2) then
      begin
        Result := -1;
      end
      else
      begin
        Result := CompareInner(temp1, temp2);
      end;
end;

function CompareVersion(str1, str2: String): Integer;
var
  temp1, temp2: String;
begin
    temp1 := str1;
    temp2 := str2;
    Result := CompareInner(temp1, temp2);
end;

// function InitializeSetup(): Boolean;
// var
  // oldVersion: String;
  // uninstaller: String;
  // ErrorCode: Integer;
  // vCurID      :String;
  // vCurAppName :String;
// begin
  // vCurID:= '{#SetupSetting("AppName")}';
  // vCurAppName:= '{#SetupSetting("AppName")}';

  // if RegKeyExists(HKLM,
    // 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + vCurID + '_is1') then
  // begin
    // RegQueryStringValue(HKLM,
      // 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + vCurID + '_is1',
      // 'DisplayVersion', oldVersion);
    // if (not (CompareVersion(oldVersion, '{#SetupSetting("AppVersion")}') = 0)) then
    // begin
      // if MsgBox('An older version ' + oldVersion + ' of ' + vCurAppName + ' is already installed. Continue to use this version?',
        // mbConfirmation, MB_YESNO) = IDYES then
      // begin
        // Result := False;
      // end
      // else
      // begin
          // RegQueryStringValue(HKLM,
            // 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + vCurID + '_is1',
            // 'UninstallString', uninstaller);
          // ShellExec('runas', uninstaller, '/SILENT', '', SW_HIDE, ewWaitUntilTerminated, ErrorCode);
          // Result := True;
      // end;
    // end
    // else
    // begin
      // if MsgBox('Version ' + oldVersion + ' of ' + vCurAppName + ' is already installed. Continue with the install?',
        // mbConfirmation, MB_YESNO) = IDNO then
      // begin
        // Result := False;
      // end
      // else
      // begin
          // RegQueryStringValue(HKLM,
            // 'SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\' + vCurID + '_is1',
            // 'UninstallString', uninstaller);
          // ShellExec('runas', uninstaller, '/SILENT', '', SW_HIDE, ewWaitUntilTerminated, ErrorCode);
          // Result := True;
      // end;
    // end
  // end
  // else
  // begin
    // Result := True;
  // end;
// end;


Both Zulu and VirtualBox now install in correct dir

; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define AppName "Red Hat Developer Platform"
#define AppVersion "1.0"
#define AppPublisher "Red Hat"
#define AppURL "http://www.redhat.com/"

#include <idp.iss>

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{C72362A0-26F3-49D6-8ED1-8214644255DD}
AppName={#AppName}
AppVersion={#AppVersion}
;AppVerName={#AppName} {#AppVersion}
AppPublisher={#AppPublisher}
AppPublisherURL={#AppURL}
AppSupportURL={#AppURL}
AppUpdatesURL={#AppURL}
CreateAppDir=yes
DefaultDirName={pf}\{#AppName}
DefaultGroupName={#AppName}
OutputBaseFilename=developer_platform
Compression=lzma
SolidCompression=yes
;WizardSmallImageFile=blank.bmp
BackColor=clWhite
BackSolid=yes
DisableWelcomePage=yes
DisableDirPage=yes
DisableReadyPage=no
DisableFinishedPage=yes
ExtraDiskSpaceRequired=1048576

[Files]

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Registry]
Root: HKLM; Subkey: "Software\Red Hat";            Flags: uninsdeletekeyifempty
Root: HKLM; Subkey: "Software\Red Hat\{#AppName}"; Flags: uninsdeletekey
Root: HKLM; Subkey: "Software\Red Hat\{#AppName}"; ValueType: string; ValueName: "InstallDir"; ValueData: "{app}"

[Code]

type
  ComponentGroup = record
    Container: TPanel;
    Content: TPanel;
  end;
  BcLabelArray = array[1..4] of TLabel;

  Component = record
    Name: String;
    DownloadUrl: String;
    Install: Boolean;
  end;

var
  // Page IDs
  AuthPageID, ComponentPageID, DownloadPageID, GetStartedPageID, InstallPageID : Integer;

  UsernameEdit: TNewEdit;
  PasswordEdit: TPasswordEdit;

  AuthLabel: TNewStaticText;

  // "Standard" blue color used throughout the installer
  StdColor: TColor;

  // Breadcrumb image
  Breadcrumbs: TBitmapImage;

  // Breadcrumb labels, we store references to these in an array for convenience
  BreadcrumbLabel: BcLabelArray;

  // Flag indicating whether the user has authenticated successfully
  IsAuthenticated: Boolean;

// Converts a color String in the format '$rrggbb' to a TColor value
function StringToColor(Color: String): TColor;
var
    RR, GG, BB: String;
    Dec: Integer;
begin
    { Change string Color from $RRGGBB to $BBGGRR and then convert to TColor }
    if((Length(Color) <> 7) or (Color[1] <> '$')) then
        Result := $000000
    else
    begin
        RR := Color[2] + Color[3];
        GG := Color[4] + Color[5];
        BB := Color[6] + Color[7];
        Dec := StrToInt('$' + BB + GG + RR);
        Result := TColor(Dec);
    end;
end;

procedure LoginButtonOnClick(Sender: TObject);
var
  Url, Resource: String;

  Page: TWizardPage;
  Button: TNewButton;
  WinHttpReq: Variant;
begin
  Page := PageFromID(AuthPageID);

  AuthLabel.Caption := 'Authenticating, please wait...';
  AuthLabel.Font.Color := clBlack;
  AuthLabel.Visible := True;
  AuthLabel.Refresh;

  Resource := 'https://access.redhat.com/jbossnetwork/restricted/listSoftware.html?product=jbossdeveloperstudio&downloadType=distributions';

  Url := 'https://idp.redhat.com/idp/authUser?j_username=' + UsernameEdit.Text + '&j_password=' + PasswordEdit.Text +
    '&redirect=' + Resource;

  // Perform a SAML authentication for redhat.com
  WinHttpReq := CreateOleObject('WinHttp.WinHttpRequest.5.1');
  WinHttpReq.Open('POST', Url, false);
  WinHttpReq.SetClientCertificate('LOCAL_MACHINE\Personal\My Certificate');
  WinHttpReq.SetRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
  WinHttpReq.Send();

  if WinHttpReq.Status <> 200 then
  begin
     AuthLabel.Caption := 'Authentication Failed.';
     AuthLabel.Font.Color := clRed;
     Exit;
  end else begin
    // Set the authenticated flag to true
    IsAuthenticated := True;

    AuthLabel.Caption := 'Authentication Successful.';
    AuthLabel.Font.Color := clGreen;

    // Simulate a click of the Next button
    WizardForm.NextButton.OnClick(nil);
  end;
end;

procedure ForgotLabelOnClick(Sender: TObject);
var
  ErrorCode: Integer;
begin
  ShellExecAsOriginalUser('open', 'http://www.redhat.com/', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
end;

// Create the welcome page - this page allows the user to log in to their Red Hat account
function createWelcomePage: TWizardPage;
var
  Page: TWizardPage;
  LoginLabel: TNewStaticText;
  ForgotLabel: TNewStaticText;
  Button: TNewButton;
begin
  Page := CreateCustomPage(wpWelcome, '', '');

  // The page has a unique id, we store it in the AuthPageID variable here so that we can refer to it elsewhere
  AuthPageID := Page.ID;

  // Create the label for the user's login name
  LoginLabel := TNewStaticText.Create(Page);
  LoginLabel.Caption := 'Log in to your Red Hat account';
  LoginLabel.Parent := Page.Surface;
  LoginLabel.Color := clWhite;
  LoginLabel.Font.Style := LoginLabel.Font.Style + [fsBold];
  LoginLabel.Font.Size := 10;

  // Create an edit control for the user's login name
  UsernameEdit := TNewEdit.Create(Page);
  UsernameEdit.Top := LoginLabel.Top + LoginLabel.Height + ScaleY(8);
  UsernameEdit.Width := Page.SurfaceWidth div 2 - ScaleX(8);
  UsernameEdit.Text := 'Red Hat Login';
  UsernameEdit.Parent := Page.Surface;

  // Create a password control for the user's password
  PasswordEdit := TPasswordEdit.Create(Page);
  PasswordEdit.Top := UsernameEdit.Top +UsernameEdit.Height + ScaleY(8);
  PasswordEdit.Width := UsernameEdit.Width;
  PasswordEdit.Text := 'Password';
  PasswordEdit.Parent := Page.Surface;

  // Create the 'LOG IN' button
  Button := TNewButton.Create(Page);
  Button.Width := ScaleX(75);
  Button.Height := ScaleY(23);
  Button.Caption := 'LOG IN';
  Button.Top := PasswordEdit.Top + PasswordEdit.Height + ScaleY(8);
  Button.OnClick := @LoginButtonOnClick;
  Button.Parent := Page.Surface;

  // Create the 'forgot password' link
  ForgotLabel := TNewStaticText.Create(Page);
  ForgotLabel.Caption := 'Forgot your login or password?';
  ForgotLabel.Cursor := crHand;
  ForgotLabel.OnClick := @ForgotLabelOnClick;
  ForgotLabel.Parent := Page.Surface;
  ForgotLabel.Color := clWhite;
  { Alter Font *after* setting Parent so the correct defaults are inherited first }
  //ForgotLabel.Font.Style := URLLabel.Font.Style + [fsUnderline];
  ForgotLabel.Font.Style := ForgotLabel.Font.Style + [fsBold];
  ForgotLabel.Font.Color := StdColor;
  ForgotLabel.Top := Button.Top + ((Button.Height - ForgotLabel.Height) / 2) + ScaleY(0);
  ForgotLabel.Left := Button.Left + Button.Width + ScaleX(20);

  // Create the authentication label.  We set its visibility to false at first, then display it later when needed
  AuthLabel := TNewStaticText.Create(Page);
  AuthLabel.Parent := Page.Surface;
  AuthLabel.Color := clWhite;
  AuthLabel.Visible := False;
  AuthLabel.Top := Button.Top + Button.Height + ScaleY(8);

  result := Page;
end;

function createComponentGroup(Page: TWizardPage; Top: integer; ComponentName: String; ComponentVersion: String;
    ComponentDescription: String; ContentHeight: integer): ComponentGroup;
var
  Panel, PanelHeader, PanelContent: TPanel;
  NameLabel, VersionLabel, DescriptionLabel: TNewStaticText;
begin
  Panel := TPanel.Create(Page);
  Panel.Parent := Page.Surface;
  Panel.Top := Top;
  Panel.BorderStyle := bsNone;
  Panel.Color := StringToColor('$d3d3d3');
  Panel.Width := 840;
  Panel.Height := ContentHeight + 40;
  Panel.BevelInner := bvNone;
  Panel.BevelOuter := bvNone;

  PanelHeader := TPanel.Create(Page);
  PanelHeader.Parent := Panel;
  PanelHeader.Top := 1;
  PanelHeader.Left := 1;
  PanelHeader.BorderStyle := bsNone;
  PanelHeader.Color := StringToColor('$f6f6f6');
  PanelHeader.Width := 838;
  PanelHeader.Height := 39;
  PanelHeader.BevelInner := bvNone;
  PanelHeader.BevelOuter := bvNone;

  NameLabel := TNewStaticText.Create(Page);
  NameLabel.Caption := ComponentName;
  NameLabel.Parent := PanelHeader;
  NameLabel.Left := 12;
  NameLabel.Top := 2;
  NameLabel.Font.Size := 11;
  NameLabel.Font.Color := StringToColor('$cc0000');
  NameLabel.Font.Style := NameLabel.Font.Style + [fsBold];

  VersionLabel := TNewStaticText.Create(Page);
  VersionLabel.Caption := ComponentVersion;
  VersionLabel.Parent := PanelHeader;
  VersionLabel.Left := NameLabel.Left + NameLabel.Width + ScaleX(4);
  VersionLabel.Top := 8;
  VersionLabel.Font.Size := 7;
  VersionLabel.Font.Color := StringToColor('$797979');

  DescriptionLabel := TNewStaticText.Create(Page);
  DescriptionLabel.Caption := ComponentDescription;
  DescriptionLabel.Parent := PanelHeader;
  DescriptionLabel.Left := 12;
  DescriptionLabel.Top := NameLabel.Top + NameLabel.Height + ScaleY(2);
  DescriptionLabel.Font.Size := 7;
  DescriptionLabel.Font.Color := StringToColor('$797979');

  PanelContent := TPanel.Create(Page);
  PanelContent.Parent := Panel;
  PanelContent.Top := 41;
  PanelContent.Left := 1;
  PanelContent.BorderStyle := bsNone;
  PanelContent.Color := clWhite;
  PanelContent.Width := 838;
  PanelContent.Height := ContentHeight - 2;
  PanelContent.BevelInner := bvNone;
  PanelContent.BevelOuter := bvNone;

  Result.Container := Panel;
  Result.Content := PanelContent;
end;

// Create the welcome page - this page allows the user to log in to their Red Hat account
function createComponentPage: TWizardPage;
var
  Page: TWizardPage;
  HeadingLabel: TNewStaticText;
  Entry: ComponentGroup;
begin
  Page := PageFromID(wpReady);

  // The page has a unique id, we store it in the AuthPageID variable here so that we can refer to it elsewhere
  //ComponentPageID := Page.ID;

  // Create the heading label for the component selection list
  HeadingLabel := TNewStaticText.Create(Page);
  HeadingLabel.Caption := 'Select the products and tools you want to install.';
  HeadingLabel.Parent := Page.Surface;
  HeadingLabel.Font.Size := 8;

  Entry := createComponentGroup(Page, HeadingLabel.Top + HeadingLabel.Height + ScaleY(8),
    'RED HAT ENTERPRISE LINUX ATOMIC PLATFORM', 'v2.0',
    'Host Linux containers in a minimal version of Red Hat Enterprise Linux.', 80);

  Entry := createComponentGroup(Page, Entry.Container.Top + Entry.Container.Height + ScaleY(8),
    'RED HAT JBOSS DEVELOPER STUDIO', 'v9.0',
    'An IDE with tooling that will help you easily code, test, and deploy your projects.', 60);

  Entry := createComponentGroup(Page, Entry.Container.Top + Entry.Container.Height + ScaleY(8),
    'RED HAT OPENSHIFT ENTERPRISE', 'v3.0',
    'DevOps tooling that helps you easily build and deploy your projects in a PaaS environment.', 40);
end;

// Create the Get Started page
function createGetStartedPage: TWizardPage;
var
  Page: TWizardPage;
begin
  Page := CreateCustomPage(wpInstalling, '', '');

  // The page has a unique id, we store it in the AuthPageID variable here so that we can refer to it elsewhere
  GetStartedPageID := Page.ID;
end;

procedure CreateWizardPages;
begin
  createWelcomePage;
  createComponentPage;
  createGetStartedPage;
end;

function createDownloadForm(PreviousPageId: Integer): Integer;
begin
    IDPForm.Page := CreateCustomPage(PreviousPageId, ExpandConstant('{cm:IDP_FormCaption}'), ExpandConstant('{cm:IDP_FormDescription}'));

    IDPForm.TotalProgressBar := TNewProgressBar.Create(IDPForm.Page);
    with IDPForm.TotalProgressBar do
    begin
        Parent := IDPForm.Page.Surface;
        Left := ScaleX(0);
        Top := ScaleY(16);
        Width := ScaleX(410);
        Height := ScaleY(20);
        Min := 0;
        Max := 100;
    end;

    IDPForm.TotalProgressLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.TotalProgressLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_TotalProgress}');
        Left := ScaleX(0);
        Top := ScaleY(0);
        Width := ScaleX(200);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 1;
    end;

    IDPForm.CurrentFileLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.CurrentFileLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_CurrentFile}');
        Left := ScaleX(0);
        Top := ScaleY(48);
        Width := ScaleX(200);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 2;
    end;

    IDPForm.FileProgressBar := TNewProgressBar.Create(IDPForm.Page);
    with IDPForm.FileProgressBar do
    begin
        Parent := IDPForm.Page.Surface;
        Left := ScaleX(0);
        Top := ScaleY(64);
        Width := ScaleX(410);
        Height := ScaleY(20);
        Min := 0;
        Max := 100;
    end;

    IDPForm.TotalDownloaded := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.TotalDownloaded do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(290);
        Top := ScaleY(0);
        Width := ScaleX(120);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 4;
    end;

    IDPForm.FileDownloaded := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.FileDownloaded do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(290);
        Top := ScaleY(48);
        Width := ScaleX(120);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 5;
    end;

    IDPForm.FileNameLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.FileNameLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_File}');
        Left := ScaleX(0);
        Top := ScaleY(100);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 6;
    end;

    IDPForm.SpeedLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.SpeedLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_Speed}');
        Left := ScaleX(0);
        Top := ScaleY(116);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 7;
    end;

    IDPForm.StatusLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.StatusLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_Status}');
        Left := ScaleX(0);
        Top := ScaleY(132);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 8;
    end;

    IDPForm.ElapsedTimeLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.ElapsedTimeLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_ElapsedTime}');
        Left := ScaleX(0);
        Top := ScaleY(148);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 9;
    end;

    IDPForm.RemainingTimeLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.RemainingTimeLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_RemainingTime}');
        Left := ScaleX(0);
        Top := ScaleY(164);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 10;
    end;

    IDPForm.FileName := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.FileName do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(100);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 11;
    end;

    IDPForm.Speed := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.Speed do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(116);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 12;
    end;

    IDPForm.Status := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.Status do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(132);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 13;
    end;

    IDPForm.ElapsedTime := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.ElapsedTime do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(148);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 14;
    end;

    IDPForm.RemainingTime := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.RemainingTime do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(164);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 15;
    end;

    IDPForm.DetailsButton := TNewButton.Create(IDPForm.Page);
    with IDPForm.DetailsButton do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_DetailsButton}');
        Left := ScaleX(336);
        Top := ScaleY(184);
        Width := ScaleX(75);
        Height := ScaleY(23);
        TabOrder := 16;
        OnClick := @idpDetailsButtonClick;
    end;

    IDPForm.InvisibleButton := TNewButton.Create(IDPForm.Page);
    with IDPForm.InvisibleButton do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('You must not see this button');
        Left := ScaleX(0);
        Top := ScaleY(0);
        Width := ScaleX(10);
        Height := ScaleY(10);
        TabOrder := 17;
        Visible := False;
        OnClick := @idpReportErrorHelper;
    end;

    with IDPForm.Page do
    begin
        OnActivate          := @idpFormActivate;
        OnShouldSkipPage    := @idpShouldSkipPage;
        OnBackButtonClick   := @idpBackButtonClick;
        OnNextButtonClick   := @idpNextButtonClick;
        OnCancelButtonClick := @idpCancelButtonClick;
    end;

    Result := IDPForm.Page.ID;
end;

procedure CustomWpInstallingPage;
var
  Page: TWizardPage;
  HeadingLabel: TNewStaticText;
begin
  Page := CreateCustomPage(wpReady, '', '');

  // Create the heading label for the component selection list
  HeadingLabel := TNewStaticText.Create(Page);
  HeadingLabel.Caption := 'Installing components';
  HeadingLabel.Parent := Page.Surface;
  HeadingLabel.Font.Size := 8;

  // Render the page

  Page.Surface.Show;
  Page.Surface.Update;
end;

procedure SelectBreadcrumb(Index: Integer);
var
  I: Integer;
  ItemColor: TColor;
begin
  for I := 1 to 4 do
  begin
    if (I = Index) then
      begin
        ItemColor := StdColor;
        BreadcrumbLabel[I].Font.Style := BreadcrumbLabel[I].Font.Style + [fsBold];
      end
    else
      begin
        ItemColor := StringToColor('$cccccc');
        BreadcrumbLabel[I].Font.Style := BreadcrumbLabel[I].Font.Style - [fsBold];
      end;

    BreadcrumbLabel[I].Font.Color := ItemColor;
    BreadcrumbLabel[I].Width := 120;
    BreadcrumbLabel[I].Alignment := taCenter;

    with Breadcrumbs.Bitmap.Canvas do
    begin
      Brush.Color := ItemColor;
      Brush.Style := bsSolid;
      Pen.Color := ItemColor;;
      Ellipse(BreadcrumbLabel[I].Left + 54, 22, BreadcrumbLabel[I].Left + 64, 12);
    end;
  end;
end;

procedure CurPageChanged(CurPageID: Integer);
begin
  if (CurPageID = AuthPageID) then
  begin
    SelectBreadcrumb(1);
    WizardForm.NextButton.Visible := False;
  end else if (CurPageID = wpReady) then
  begin
    SelectBreadcrumb(2);
  end else if (CurPageID = DownloadPageID) then
  begin
    SelectBreadcrumb(3);
    WizardForm.NextButton.Visible := False;
  end else if (CurPageID = GetStartedPageID) then
  begin
    SelectBreadcrumb(4);
    WizardForm.NextButton.Visible := True;
    WizardForm.BackButton.Visible := False;
    WizardForm.NextButton.Caption := 'Close';
  end;

  if (CurPageID = wpInstalling) then
  begin
    CustomWpInstallingPage();
  end;
end;

procedure CurStepChanged(CurStep: TSetupStep);
var
  ErrorCode: Integer;
begin
  if CurStep = ssInstall then
  begin
    // Install Zulu JDK
    ShellExec('', 'msiexec', ExpandConstant('/i {tmp}\zulu1.8.0_60-8.9.0.4-win64.msi INSTALLDIR="{app}\zulu-8" /passive /norestart'),
        '', SW_SHOW, ewWaitUntilTerminated, ErrorCode);

    // Extract the VirtualBox msi files from the downloaded exe
    Shellexec('', ExpandConstant('{tmp}\VirtualBox-5.0.2-102096-Win.exe'), ExpandConstant('--extract -path {tmp} --silent'),
        '', SW_SHOW, ewWaitUntilTerminated, ErrorCode);

    // Install VirtualBox
    ShellExec('', 'msiexec', ExpandConstant('/i {tmp}\VirtualBox-5.0.2-r102096-MultiArch_x86.msi INSTALLDIR="{app}\VirtualBox" /passive /norestart'),
        '', SW_SHOW, ewWaitUntilTerminated, ErrorCode);

    //ShellExec('', 'msiexec', ExpandConstant('/i {tmp}\VirtualBox-5.0.2-102096-Win.exe IN
    //ShellExec('', 'msiexec', ExpandConstant('/i {tmp}\zulu1.8.0_51-8.8.0.3-win64.msi /passive /norestart /log "{app}\zulu_install_log.txt"'),
    //    '', SW_SHOW, ewWaitUntilTerminated, ErrorCode);
  end;

end;

procedure CreateBreadcrumbLabel(Index: Integer; Caption: String);
begin
  BreadcrumbLabel[Index] := TLabel.Create(WizardForm.MainPanel);
  BreadcrumbLabel[Index].Caption := Caption;
  BreadcrumbLabel[Index].Parent := WizardForm.MainPanel;
  BreadcrumbLabel[Index].Font.Color := StringToColor('$cccccc');
  BreadcrumbLabel[Index].Font.Size := 8;
  BreadcrumbLabel[Index].Top := 24;
  BreadcrumbLabel[Index].Left := 36 + ((Index - 1) * 120);
  BreadcrumbLabel[Index].Width := 120;
  BreadcrumbLabel[Index].Alignment := taCenter;
end;

procedure InitializeWizard();
var
  BackgroundBitmapImage: TBitmapImage;
  BackgroundBitmapText: TNewStaticText;
  BitmapFileName: String;
begin
  StdColor := StringToColor('$0093d9');

  { Custom wizard pages }

  WizardForm.PageNameLabel.Visible := False;
  WizardForm.PageDescriptionLabel.Visible := False;

  WizardForm.OuterNotebook.Width := 880;
  WizardForm.OuterNotebook.Height := 460;

  WizardForm.InnerNotebook.Width := 880;
  WizardForm.InnerNotebook.Height := 460;

  // Set the width of the top panel
  WizardForm.MainPanel.Width := 920;

  WizardForm.WizardSmallBitmapImage.Visible := false;

  Breadcrumbs := TBitmapImage.Create(WizardForm.MainPanel);
  Breadcrumbs.Parent := WizardForm.MainPanel;
  Breadcrumbs.Top := 0;
  Breadcrumbs.Left := 0;
  Breadcrumbs.Width := 600;
  Breadcrumbs.Height := 50;
  Breadcrumbs.AutoSize := True;

  Breadcrumbs.Bitmap.Height := 50;
  Breadcrumbs.Bitmap.Width := 600;

  with Breadcrumbs.Bitmap.Canvas do
  begin
    Pen.Color := StringToColor('$cccccc');
    MoveTo(1, 16);
    LineTo(460,16);
  end;

  // Create the breadcrumb labels
  CreateBreadcrumbLabel(1, 'Install Setup');
  CreateBreadcrumbLabel(2, 'Confirmation');
  CreateBreadcrumbLabel(3, 'Download && Install');
  CreateBreadcrumbLabel(4, 'Get Started');

  WizardForm.BorderStyle := bsSingle;
  WizardForm.Color := clWhite;

  // These lines change the width and height of the wizard window, but components need to be repositioned
  WizardForm.Width := 940;
  WizardForm.Height := 565;
  WizardForm.Position := poScreenCenter;

  // Let's just hide the cancel button, if the user wishes to cancel they can just close the installer window
  WizardForm.CancelButton.Visible := False;
  //WizardForm.CancelButton.Top := 500;
  //WizardForm.CancelButton.Left := 32;

  WizardForm.NextButton.Top := 500;
  WizardForm.NextButton.Left := 840;

  WizardForm.BackButton.Top := 500;
  WizardForm.BackButton.Left := 32;

  WizardForm.Bevel.Visible := False;
  WizardForm.Bevel1.Visible := False;

  // Sets the background color of the inner panel to white
  WizardForm.InnerPage.Color := clWhite;

  CreateWizardPages;

  // Show details by default
  idpSetOption('DetailedMode', '1');

  // Hide the 'Details' button
  idpSetOption('DetailsButton', '0');

  // Zulu
  //idpSetOption('Referer', 'http://www.azulsystems.com/products/zulu/downloads');
  //idpAddFile('http://cdn.azulsystems.com/zulu/2015-07-8.8-bin/zulu1.8.0_51-8.8.0.3-win64.msi', ExpandConstant('{tmp}\zulu1.8.0_51-8.8.0.3-win64.msi'));
  idpAddFile('http://192.168.1.114/~shane/zulu1.8.0_60-8.9.0.4-win64.msi', ExpandConstant('{tmp}\zulu1.8.0_60-8.9.0.4-win64.msi'));

  // VirtualBox
  //idpAddFile('http://download.virtualbox.org/virtualbox/5.0.2/VirtualBox-5.0.2-102096-Win.exe', ExpandConstant('{tmp}\VirtualBox-5.0.2-102096-Win.exe'));
  idpAddFile('http://192.168.1.114/~shane/VirtualBox-5.0.2-102096-Win.exe', ExpandConstant('{tmp}\VirtualBox-5.0.2-102096-Win.exe'));

  //idpAddFile('https://dl.bintray.com/mitchellh/vagrant/vagrant_1.7.4.msi', 'Vagrant');

  idpDownloadAfter(wpReady);

  DownloadPageID := createDownloadForm(wpReady);

  idpConnectControls;
  idpInitMessages;
end;

; Script generated by the Inno Setup Script Wizard.
; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES!

#define AppName "Red Hat Developer Platform"
#define AppVersion "1.0"
#define AppPublisher "Red Hat"
#define AppURL "http://www.redhat.com/"

#include <idp.iss>

[Setup]
; NOTE: The value of AppId uniquely identifies this application.
; Do not use the same AppId value in installers for other applications.
; (To generate a new GUID, click Tools | Generate GUID inside the IDE.)
AppId={{C72362A0-26F3-49D6-8ED1-8214644255DD}
AppName={#AppName}
AppVersion={#AppVersion}
;AppVerName={#AppName} {#AppVersion}
AppPublisher={#AppPublisher}
AppPublisherURL={#AppURL}
AppSupportURL={#AppURL}
AppUpdatesURL={#AppURL}
CreateAppDir=yes
DefaultDirName={pf}\{#AppName}
DefaultGroupName={#AppName}
OutputBaseFilename=developer_platform
Compression=lzma
SolidCompression=yes
;WizardSmallImageFile=blank.bmp
BackColor=clWhite
BackSolid=yes
DisableWelcomePage=yes
DisableDirPage=yes
DisableReadyPage=no
DisableFinishedPage=yes
ExtraDiskSpaceRequired=1048576

[Files]

[Languages]
Name: "english"; MessagesFile: "compiler:Default.isl"

[Registry]
Root: HKLM; Subkey: "Software\Red Hat";            Flags: uninsdeletekeyifempty
Root: HKLM; Subkey: "Software\Red Hat\{#AppName}"; Flags: uninsdeletekey
Root: HKLM; Subkey: "Software\Red Hat\{#AppName}"; ValueType: string; ValueName: "InstallDir"; ValueData: "{app}"

[Code]

type
  ComponentEntry = record
    Container: TPanel;
    Content: TPanel;
  end;
  BcLabelArray = array[1..4] of TLabel;

var
  // Page IDs
  AuthPageID, ComponentPageID, DownloadPageID, GetStartedPageID, InstallPageID : Integer;

  UsernameEdit: TNewEdit;
  PasswordEdit: TPasswordEdit;

  AuthLabel: TNewStaticText;

  // "Standard" blue color used throughout the installer
  StdColor: TColor;

  // Breadcrumb image
  Breadcrumbs: TBitmapImage;

  // Breadcrumb labels, we store references to these in an array for convenience
  BreadcrumbLabel: BcLabelArray;

  // Flag indicating whether the user has authenticated successfully
  IsAuthenticated: Boolean;

// Converts a color String in the format '$rrggbb' to a TColor value
function StringToColor(Color: String): TColor;
var
    RR, GG, BB: String;
    Dec: Integer;
begin
    { Change string Color from $RRGGBB to $BBGGRR and then convert to TColor }
    if((Length(Color) <> 7) or (Color[1] <> '$')) then
        Result := $000000
    else
    begin
        RR := Color[2] + Color[3];
        GG := Color[4] + Color[5];
        BB := Color[6] + Color[7];
        Dec := StrToInt('$' + BB + GG + RR);
        Result := TColor(Dec);
    end;
end;

procedure LoginButtonOnClick(Sender: TObject);
var
  Url, Resource: String;
  Page: TWizardPage;
  Button: TNewButton;
  WinHttpReq: Variant;
begin
  Page := PageFromID(AuthPageID);

  AuthLabel.Caption := 'Authenticating, please wait...';
  AuthLabel.Font.Color := clBlack;
  AuthLabel.Visible := True;
  AuthLabel.Refresh;

  Resource := 'https://access.redhat.com/jbossnetwork/restricted/listSoftware.html?product=jbossdeveloperstudio&downloadType=distributions';

  Url := 'https://idp.redhat.com/idp/authUser?j_username=' + UsernameEdit.Text + '&j_password=' + PasswordEdit.Text +
    '&redirect=' + Resource;

  // Perform a SAML authentication for redhat.com
  WinHttpReq := CreateOleObject('WinHttp.WinHttpRequest.5.1');
  WinHttpReq.Open('POST', Url, false);
  WinHttpReq.SetClientCertificate('LOCAL_MACHINE\Personal\My Certificate');
  WinHttpReq.SetRequestHeader('Content-Type', 'application/x-www-form-urlencoded');
  WinHttpReq.Send();

  if WinHttpReq.Status <> 200 then
  begin
     AuthLabel.Caption := 'Authentication Failed.';
     AuthLabel.Font.Color := clRed;
     Exit;
  end else begin
    // Set the authenticated flag to true
    IsAuthenticated := True;

    AuthLabel.Caption := 'Authentication Successful.';
    AuthLabel.Font.Color := clGreen;

    // Simulate a click of the Next button
    WizardForm.NextButton.OnClick(nil);
  end;
end;

procedure ForgotLabelOnClick(Sender: TObject);
var
  ErrorCode: Integer;
begin
  ShellExecAsOriginalUser('open', 'http://www.redhat.com/', '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
end;

// Create the welcome page - this page allows the user to log in to their Red Hat account
function createWelcomePage: TWizardPage;
var
  Page: TWizardPage;
  LoginLabel: TNewStaticText;
  ForgotLabel: TNewStaticText;
  Button: TNewButton;
begin
  Page := CreateCustomPage(wpWelcome, '', '');

  // The page has a unique id, we store it in the AuthPageID variable here so that we can refer to it elsewhere
  AuthPageID := Page.ID;

  // Create the label for the user's login name
  LoginLabel := TNewStaticText.Create(Page);
  LoginLabel.Caption := 'Log in to your Red Hat account';
  LoginLabel.Parent := Page.Surface;
  LoginLabel.Color := clWhite;
  LoginLabel.Font.Style := LoginLabel.Font.Style + [fsBold];
  LoginLabel.Font.Size := 10;

  // Create an edit control for the user's login name
  UsernameEdit := TNewEdit.Create(Page);
  UsernameEdit.Top := LoginLabel.Top + LoginLabel.Height + ScaleY(8);
  UsernameEdit.Width := Page.SurfaceWidth div 2 - ScaleX(8);
  UsernameEdit.Text := 'Red Hat Login';
  UsernameEdit.Parent := Page.Surface;

  // Create a password control for the user's password
  PasswordEdit := TPasswordEdit.Create(Page);
  PasswordEdit.Top := UsernameEdit.Top +UsernameEdit.Height + ScaleY(8);
  PasswordEdit.Width := UsernameEdit.Width;
  PasswordEdit.Text := 'Password';
  PasswordEdit.Parent := Page.Surface;

  // Create the 'LOG IN' button
  Button := TNewButton.Create(Page);
  Button.Width := ScaleX(75);
  Button.Height := ScaleY(23);
  Button.Caption := 'LOG IN';
  Button.Top := PasswordEdit.Top + PasswordEdit.Height + ScaleY(8);
  Button.OnClick := @LoginButtonOnClick;
  Button.Parent := Page.Surface;

  // Create the 'forgot password' link
  ForgotLabel := TNewStaticText.Create(Page);
  ForgotLabel.Caption := 'Forgot your login or password?';
  ForgotLabel.Cursor := crHand;
  ForgotLabel.OnClick := @ForgotLabelOnClick;
  ForgotLabel.Parent := Page.Surface;
  ForgotLabel.Color := clWhite;
  { Alter Font *after* setting Parent so the correct defaults are inherited first }
  //ForgotLabel.Font.Style := URLLabel.Font.Style + [fsUnderline];
  ForgotLabel.Font.Style := ForgotLabel.Font.Style + [fsBold];
  ForgotLabel.Font.Color := StdColor;
  ForgotLabel.Top := Button.Top + ((Button.Height - ForgotLabel.Height) / 2) + ScaleY(0);
  ForgotLabel.Left := Button.Left + Button.Width + ScaleX(20);

  // Create the authentication label.  We set its visibility to false at first, then display it later when needed
  AuthLabel := TNewStaticText.Create(Page);
  AuthLabel.Parent := Page.Surface;
  AuthLabel.Color := clWhite;
  AuthLabel.Visible := False;
  AuthLabel.Top := Button.Top + Button.Height + ScaleY(8);

  result := Page;
end;

function createComponentEntry(Page: TWizardPage; Top: integer; ComponentName: String; ComponentVersion: String;
    ComponentDescription: String; ContentHeight: integer): ComponentEntry;
var
  Panel, PanelHeader, PanelContent: TPanel;
  NameLabel, VersionLabel, DescriptionLabel: TNewStaticText;
begin
  Panel := TPanel.Create(Page);
  Panel.Parent := Page.Surface;
  Panel.Top := Top;
  Panel.BorderStyle := bsNone;
  Panel.Color := StringToColor('$d3d3d3');
  Panel.Width := 840;
  Panel.Height := ContentHeight + 40;
  Panel.BevelInner := bvNone;
  Panel.BevelOuter := bvNone;

  PanelHeader := TPanel.Create(Page);
  PanelHeader.Parent := Panel;
  PanelHeader.Top := 1;
  PanelHeader.Left := 1;
  PanelHeader.BorderStyle := bsNone;
  PanelHeader.Color := StringToColor('$f6f6f6');
  PanelHeader.Width := 838;
  PanelHeader.Height := 39;
  PanelHeader.BevelInner := bvNone;
  PanelHeader.BevelOuter := bvNone;

  NameLabel := TNewStaticText.Create(Page);
  NameLabel.Caption := ComponentName;
  NameLabel.Parent := PanelHeader;
  NameLabel.Left := 12;
  NameLabel.Top := 2;
  NameLabel.Font.Size := 11;
  NameLabel.Font.Color := StringToColor('$cc0000');
  NameLabel.Font.Style := NameLabel.Font.Style + [fsBold];

  VersionLabel := TNewStaticText.Create(Page);
  VersionLabel.Caption := ComponentVersion;
  VersionLabel.Parent := PanelHeader;
  VersionLabel.Left := NameLabel.Left + NameLabel.Width + ScaleX(4);
  VersionLabel.Top := 8;
  VersionLabel.Font.Size := 7;
  VersionLabel.Font.Color := StringToColor('$797979');

  DescriptionLabel := TNewStaticText.Create(Page);
  DescriptionLabel.Caption := ComponentDescription;
  DescriptionLabel.Parent := PanelHeader;
  DescriptionLabel.Left := 12;
  DescriptionLabel.Top := NameLabel.Top + NameLabel.Height + ScaleY(2);
  DescriptionLabel.Font.Size := 7;
  DescriptionLabel.Font.Color := StringToColor('$797979');

  PanelContent := TPanel.Create(Page);
  PanelContent.Parent := Panel;
  PanelContent.Top := 41;
  PanelContent.Left := 1;
  PanelContent.BorderStyle := bsNone;
  PanelContent.Color := clWhite;
  PanelContent.Width := 838;
  PanelContent.Height := ContentHeight - 2;
  PanelContent.BevelInner := bvNone;
  PanelContent.BevelOuter := bvNone;

  Result.Container := Panel;
  Result.Content := PanelContent;
end;

// Create the welcome page - this page allows the user to log in to their Red Hat account
function createComponentPage: TWizardPage;
var
  Page: TWizardPage;
  HeadingLabel: TNewStaticText;
  Entry: ComponentEntry;
begin
  Page := PageFromID(wpReady);

  // The page has a unique id, we store it in the AuthPageID variable here so that we can refer to it elsewhere
  //ComponentPageID := Page.ID;

  // Create the heading label for the component selection list
  HeadingLabel := TNewStaticText.Create(Page);
  HeadingLabel.Caption := 'Select the products and tools you want to install.';
  HeadingLabel.Parent := Page.Surface;
  HeadingLabel.Font.Size := 8;

  Entry := createComponentEntry(Page, HeadingLabel.Top + HeadingLabel.Height + ScaleY(8),
    'RED HAT ENTERPRISE LINUX ATOMIC PLATFORM', 'v2.0',
    'Host Linux containers in a minimal version of Red Hat Enterprise Linux.', 80);

  Entry := createComponentEntry(Page, Entry.Container.Top + Entry.Container.Height + ScaleY(8),
    'RED HAT JBOSS DEVELOPER STUDIO', 'v9.0',
    'An IDE with tooling that will help you easily code, test, and deploy your projects.', 60);

  Entry := createComponentEntry(Page, Entry.Container.Top + Entry.Container.Height + ScaleY(8),
    'RED HAT OPENSHIFT ENTERPRISE', 'v3.0',
    'DevOps tooling that helps you easily build and deploy your projects in a PaaS environment.', 40);
end;

// Create the Get Started page
function createGetStartedPage: TWizardPage;
var
  Page: TWizardPage;
begin
  Page := CreateCustomPage(wpInstalling, '', '');

  // The page has a unique id, we store it in the AuthPageID variable here so that we can refer to it elsewhere
  GetStartedPageID := Page.ID;
end;

procedure CreateWizardPages;
begin
  createWelcomePage;
  createComponentPage;
  createGetStartedPage;
end;

function createDownloadForm(PreviousPageId: Integer): Integer;
begin
    IDPForm.Page := CreateCustomPage(PreviousPageId, ExpandConstant('{cm:IDP_FormCaption}'), ExpandConstant('{cm:IDP_FormDescription}'));

    IDPForm.TotalProgressBar := TNewProgressBar.Create(IDPForm.Page);
    with IDPForm.TotalProgressBar do
    begin
        Parent := IDPForm.Page.Surface;
        Left := ScaleX(0);
        Top := ScaleY(16);
        Width := ScaleX(410);
        Height := ScaleY(20);
        Min := 0;
        Max := 100;
    end;

    IDPForm.TotalProgressLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.TotalProgressLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_TotalProgress}');
        Left := ScaleX(0);
        Top := ScaleY(0);
        Width := ScaleX(200);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 1;
    end;

    IDPForm.CurrentFileLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.CurrentFileLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_CurrentFile}');
        Left := ScaleX(0);
        Top := ScaleY(48);
        Width := ScaleX(200);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 2;
    end;

    IDPForm.FileProgressBar := TNewProgressBar.Create(IDPForm.Page);
    with IDPForm.FileProgressBar do
    begin
        Parent := IDPForm.Page.Surface;
        Left := ScaleX(0);
        Top := ScaleY(64);
        Width := ScaleX(410);
        Height := ScaleY(20);
        Min := 0;
        Max := 100;
    end;

    IDPForm.TotalDownloaded := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.TotalDownloaded do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(290);
        Top := ScaleY(0);
        Width := ScaleX(120);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 4;
    end;

    IDPForm.FileDownloaded := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.FileDownloaded do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(290);
        Top := ScaleY(48);
        Width := ScaleX(120);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 5;
    end;

    IDPForm.FileNameLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.FileNameLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_File}');
        Left := ScaleX(0);
        Top := ScaleY(100);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 6;
    end;

    IDPForm.SpeedLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.SpeedLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_Speed}');
        Left := ScaleX(0);
        Top := ScaleY(116);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 7;
    end;

    IDPForm.StatusLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.StatusLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_Status}');
        Left := ScaleX(0);
        Top := ScaleY(132);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 8;
    end;

    IDPForm.ElapsedTimeLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.ElapsedTimeLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_ElapsedTime}');
        Left := ScaleX(0);
        Top := ScaleY(148);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 9;
    end;

    IDPForm.RemainingTimeLabel := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.RemainingTimeLabel do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_RemainingTime}');
        Left := ScaleX(0);
        Top := ScaleY(164);
        Width := ScaleX(116);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 10;
    end;

    IDPForm.FileName := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.FileName do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(100);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 11;
    end;

    IDPForm.Speed := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.Speed do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(116);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 12;
    end;

    IDPForm.Status := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.Status do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(132);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 13;
    end;

    IDPForm.ElapsedTime := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.ElapsedTime do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(148);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 14;
    end;

    IDPForm.RemainingTime := TNewStaticText.Create(IDPForm.Page);
    with IDPForm.RemainingTime do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := '';
        Left := ScaleX(120);
        Top := ScaleY(164);
        Width := ScaleX(280);
        Height := ScaleY(14);
        AutoSize := False;
        TabOrder := 15;
    end;

    IDPForm.DetailsButton := TNewButton.Create(IDPForm.Page);
    with IDPForm.DetailsButton do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('{cm:IDP_DetailsButton}');
        Left := ScaleX(336);
        Top := ScaleY(184);
        Width := ScaleX(75);
        Height := ScaleY(23);
        TabOrder := 16;
        OnClick := @idpDetailsButtonClick;
    end;

    IDPForm.InvisibleButton := TNewButton.Create(IDPForm.Page);
    with IDPForm.InvisibleButton do
    begin
        Parent := IDPForm.Page.Surface;
        Caption := ExpandConstant('You must not see this button');
        Left := ScaleX(0);
        Top := ScaleY(0);
        Width := ScaleX(10);
        Height := ScaleY(10);
        TabOrder := 17;
        Visible := False;
        OnClick := @idpReportErrorHelper;
    end;

    with IDPForm.Page do
    begin
        OnActivate          := @idpFormActivate;
        OnShouldSkipPage    := @idpShouldSkipPage;
        OnBackButtonClick   := @idpBackButtonClick;
        OnNextButtonClick   := @idpNextButtonClick;
        OnCancelButtonClick := @idpCancelButtonClick;
    end;

    Result := IDPForm.Page.ID;
end;

procedure CustomWpInstallingPage;
var
  Page: TWizardPage;
  HeadingLabel: TNewStaticText;
begin
  Page := CreateCustomPage(wpReady, '', '');

  // Create the heading label for the component selection list
  HeadingLabel := TNewStaticText.Create(Page);
  HeadingLabel.Caption := 'Installing components';
  HeadingLabel.Parent := Page.Surface;
  HeadingLabel.Font.Size := 8;

  // Render the page

  Page.Surface.Show;
  Page.Surface.Update;
end;

procedure SelectBreadcrumb(Index: Integer);
var
  I: Integer;
  ItemColor: TColor;
begin
  for I := 1 to 4 do
  begin
    if (I = Index) then
      begin
        ItemColor := StdColor;
        BreadcrumbLabel[I].Font.Style := BreadcrumbLabel[I].Font.Style + [fsBold];
      end
    else
      begin
        ItemColor := StringToColor('$cccccc');
        BreadcrumbLabel[I].Font.Style := BreadcrumbLabel[I].Font.Style - [fsBold];
      end;

    BreadcrumbLabel[I].Font.Color := ItemColor;
    BreadcrumbLabel[I].Width := 120;
    BreadcrumbLabel[I].Alignment := taCenter;

    with Breadcrumbs.Bitmap.Canvas do
    begin
      Brush.Color := ItemColor;
      Brush.Style := bsSolid;
      Pen.Color := ItemColor;;
      Ellipse(BreadcrumbLabel[I].Left + 54, 22, BreadcrumbLabel[I].Left + 64, 12);
    end;
  end;
end;

procedure CurPageChanged(CurPageID: Integer);
begin
  if (CurPageID = AuthPageID) then
  begin
    SelectBreadcrumb(1);
    WizardForm.NextButton.Visible := False;
  end else if (CurPageID = wpReady) then
  begin
    SelectBreadcrumb(2);
  end else if (CurPageID = DownloadPageID) then
  begin
    SelectBreadcrumb(3);
    WizardForm.NextButton.Visible := False;
  end else if (CurPageID = GetStartedPageID) then
  begin
    SelectBreadcrumb(4);
    WizardForm.NextButton.Visible := True;
    WizardForm.BackButton.Visible := False;
  end;

  if (CurPageID = wpInstalling) then
  begin
    CustomWpInstallingPage();
  end;
end;

procedure CurStepChanged(CurStep: TSetupStep);
var
  ErrorCode: Integer;
begin
  if CurStep = ssInstall then
  begin
    ShellExec('', 'msiexec', ExpandConstant('/i {tmp}\zulu1.8.0_51-8.8.0.3-win64.msi /passive /norestart TARGETDIR="{app}\zulu-8"'),
        '', SW_SHOW, ewWaitUntilTerminated, ErrorCode);

    //ShellExec('', 'msiexec', ExpandConstant('/i {tmp}\zulu1.8.0_51-8.8.0.3-win64.msi /passive /norestart /log "{app}\zulu_install_log.txt"'),
    //    '', SW_SHOW, ewWaitUntilTerminated, ErrorCode);
  end;

end;

procedure CreateBreadcrumbLabel(Index: Integer; Caption: String);
begin
  BreadcrumbLabel[Index] := TLabel.Create(WizardForm.MainPanel);
  BreadcrumbLabel[Index].Caption := Caption;
  BreadcrumbLabel[Index].Parent := WizardForm.MainPanel;
  BreadcrumbLabel[Index].Font.Color := StringToColor('$cccccc');
  BreadcrumbLabel[Index].Font.Size := 8;
  BreadcrumbLabel[Index].Top := 24;
  BreadcrumbLabel[Index].Left := 36 + ((Index - 1) * 120);
  BreadcrumbLabel[Index].Width := 120;
  BreadcrumbLabel[Index].Alignment := taCenter;
end;

procedure InitializeWizard();
var
  BackgroundBitmapImage: TBitmapImage;
  BackgroundBitmapText: TNewStaticText;
  BitmapFileName: String;
begin
  StdColor := StringToColor('$0093d9');

  { Custom wizard pages }

  WizardForm.PageNameLabel.Visible := False;
  WizardForm.PageDescriptionLabel.Visible := False;

  WizardForm.OuterNotebook.Width := 880;
  WizardForm.OuterNotebook.Height := 460;

  WizardForm.InnerNotebook.Width := 880;
  WizardForm.InnerNotebook.Height := 460;

  // Set the width of the top panel
  WizardForm.MainPanel.Width := 920;

  WizardForm.WizardSmallBitmapImage.Visible := false;

  Breadcrumbs := TBitmapImage.Create(WizardForm.MainPanel);
  Breadcrumbs.Parent := WizardForm.MainPanel;
  Breadcrumbs.Top := 0;
  Breadcrumbs.Left := 0;
  Breadcrumbs.Width := 600;
  Breadcrumbs.Height := 50;
  Breadcrumbs.AutoSize := True;

  Breadcrumbs.Bitmap.Height := 50;
  Breadcrumbs.Bitmap.Width := 600;

  with Breadcrumbs.Bitmap.Canvas do
  begin
    Pen.Color := StringToColor('$cccccc');
    MoveTo(1, 16);
    LineTo(460,16);
  end;

  // Create the breadcrumb labels
  CreateBreadcrumbLabel(1, 'Install Setup');
  CreateBreadcrumbLabel(2, 'Confirmation');
  CreateBreadcrumbLabel(3, 'Download && Install');
  CreateBreadcrumbLabel(4, 'Get Started');

  WizardForm.BorderStyle := bsSingle;
  WizardForm.Color := clWhite;

  // These lines change the width and height of the wizard window, but components need to be repositioned
  WizardForm.Width := 940;
  WizardForm.Height := 565;
  WizardForm.Position := poScreenCenter;

  // Let's just hide the cancel button, if the user wishes to cancel they can just close the installer window
  WizardForm.CancelButton.Visible := False;
  //WizardForm.CancelButton.Top := 500;
  //WizardForm.CancelButton.Left := 32;

  WizardForm.NextButton.Top := 500;
  WizardForm.NextButton.Left := 840;

  WizardForm.BackButton.Top := 500;
  WizardForm.BackButton.Left := 32;

  WizardForm.Bevel.Visible := False;
  WizardForm.Bevel1.Visible := False;

  // Sets the background color of the inner panel to white
  WizardForm.InnerPage.Color := clWhite;

  CreateWizardPages;

  // Show details by default
  idpSetOption('DetailedMode', '1');

  // Hide the 'Details' button
  idpSetOption('DetailsButton', '0');

  idpSetOption('Referer', 'http://www.azulsystems.com/products/zulu/downloads');
  idpAddFile('http://cdn.azulsystems.com/zulu/2015-07-8.8-bin/zulu1.8.0_51-8.8.0.3-win64.msi', ExpandConstant('{tmp}\zulu1.8.0_51-8.8.0.3-win64.msi'));

  //idpAddFile('http://download.virtualbox.org/virtualbox/5.0.2/VirtualBox-5.0.2-102096-Win.exe', 'VirtualBox');
  //idpAddFile('https://dl.bintray.com/mitchellh/vagrant/vagrant_1.7.4.msi', 'Vagrant');

  idpDownloadAfter(wpReady);

  DownloadPageID := createDownloadForm(wpReady);

  idpConnectControls;
  idpInitMessages;
end;


Added the test suite and wchar_t versions of the DLL.

; Basic setup script for the Inno Setep installer builder.  For more
; information on the free installer builder, see www.jrsoftware.org.
;
; This script was contributed by Tim Peters.

[Setup]
AppName=expat
AppId=expat
AppVersion=1.95.3
AppVerName=expat 1.95.3
AppCopyright=Copyright  1998-2002 Thai Open Source Software Center, Clark Cooper, and the Expat maintainers
DefaultDirName={sd}\Expat-1.95.3
AppPublisher=The Expat Developers
AppPublisherURL=http://expat.sourceforge.net/
AppSupportURL=http://expat.sourceforge.net/
AppUpdatesURL=http://expat.sourceforge.net/
UninstallDisplayName=Expat XML Parser (version 1.95.3)
UninstallFilesDir={app}\Uninstall

CompressLevel=9
SourceDir=..
OutputDir=win32
DisableStartupPrompt=yes
AllowNoIcons=yes
DisableProgramGroupPage=yes
DisableReadyPage=yes

[Files]
CopyMode: alwaysoverwrite; Source: xmlwf\Release\*.exe; DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: win32\MANIFEST.txt;  DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: COPYING;             DestDir: "{app}"; DestName: COPYING.txt
CopyMode: alwaysoverwrite; Source: NEWS;                DestDir: "{app}"; DestName: NEWS.txt
CopyMode: alwaysoverwrite; Source: README;              DestDir: "{app}"; DestName: README.txt
CopyMode: alwaysoverwrite; Source: doc\*.html;          DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: doc\*.css;           DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: lib\Release\*.dll;   DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release\*.lib;   DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release-w\*.dll; DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release-w\*.lib; DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: expat.dsw;           DestDir: "{app}\Source"
CopyMode: alwaysoverwrite; Source: lib\*.c;             DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.h;             DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.dsp;           DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: examples\*.c;        DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: examples\*.dsp;      DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: tests\*.c;           DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: tests\*.h;           DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: tests\README.txt;    DestDir: "{app}\Source\tests"
CopyMode: alwaysoverwrite; Source: xmlwf\*.c*;          DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.h;           DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.dsp;         DestDir: "{app}\Source\xmlwf"

[Messages]
WelcomeLabel1=Welcome to the Expat XML Parser Setup Wizard
WelcomeLabel2=This will install [name/ver] on your computer.%n%nExpat is an XML parser with a C-language API, and is primarily made available to allow developers to build applications which use XML using a portable API and fast implementation.%n%nIt is strongly recommended that you close all other applications you have running before continuing. This will help prevent any conflicts during the installation process.

; Basic setup script for the Inno Setep installer builder.  For more
; information on the free installer builder, see www.jrsoftware.org.
;
; This script was contributed by Tim Peters.

[Setup]
AppName=expat
AppId=expat
AppVersion=1.95.3
AppVerName=expat 1.95.3
AppCopyright=Copyright  1998-2001 Thai Open Source Software Center, Clark Cooper, and the Expat maintainers
DefaultDirName={sd}\Expat-1.95.3
AppPublisher=The Expat Developers
AppPublisherURL=http://expat.sourceforge.net/
AppSupportURL=http://expat.sourceforge.net/
AppUpdatesURL=http://expat.sourceforge.net/
UninstallDisplayName=Expat XML Parser (version 1.95.3)
UninstallFilesDir={app}\Uninstall

CompressLevel=9
SourceDir=..
OutputDir=win32
DisableStartupPrompt=yes
AllowNoIcons=yes
DisableProgramGroupPage=yes
DisableReadyPage=yes

[Files]
CopyMode: alwaysoverwrite; Source: xmlwf\Release\*.exe; DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: win32\MANIFEST.txt;  DestDir: "{app}"
CopyMode: alwaysoverwrite; Source: COPYING;             DestDir: "{app}"; DestName: COPYING.txt
CopyMode: alwaysoverwrite; Source: NEWS;                DestDir: "{app}"; DestName: NEWS.txt
CopyMode: alwaysoverwrite; Source: README;              DestDir: "{app}"; DestName: README.txt
CopyMode: alwaysoverwrite; Source: doc\*.html;          DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: doc\*.css;           DestDir: "{app}\Doc"
CopyMode: alwaysoverwrite; Source: lib\Release\*.dll;   DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: lib\Release\*.lib;   DestDir: "{app}\Libs"
CopyMode: alwaysoverwrite; Source: expat.dsw;           DestDir: "{app}\Source"
CopyMode: alwaysoverwrite; Source: lib\*.c;             DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.h;             DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: lib\*.dsp;           DestDir: "{app}\Source\lib"
CopyMode: alwaysoverwrite; Source: examples\*.c;        DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: examples\*.dsp;      DestDir: "{app}\Source\examples"
CopyMode: alwaysoverwrite; Source: xmlwf\*.c*;          DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.h;           DestDir: "{app}\Source\xmlwf"
CopyMode: alwaysoverwrite; Source: xmlwf\*.dsp;         DestDir: "{app}\Source\xmlwf"

[Messages]
WelcomeLabel1=Welcome to the Expat XML Parser Setup Wizard
WelcomeLabel2=This will install [name/ver] on your computer.%n%nExpat is an XML parser with a C-language API, and is primarily made available to allow developers to build applications which use XML using a portable API and fast implementation.%n%nIt is strongly recommended that you close all other applications you have running before continuing. This will help prevent any conflicts during the installation process.