; Script generated by the Inno Setup Script Wizard. ; SEE THE DOCUMENTATION FOR DETAILS ON CREATING INNO SETUP SCRIPT FILES! #define MyAppName "Tahoma2D" #define MyAppVersion "1.4" #define MyAppPublisher "Tahoma2D" #define MyAppURL "https://tahoma2d.org/" #define MyAppExeName "Tahoma2D.exe" [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={{0BAD1682-048C-4657-82CF-23B98C0B5F33} AppName={#MyAppName} AppVersion={#MyAppVersion} ;AppVerName={#MyAppName} {#MyAppVersion} AppPublisher={#MyAppPublisher} AppPublisherURL={#MyAppURL} AppSupportURL={#MyAppURL} AppUpdatesURL={#MyAppURL} DefaultDirName={commonpf}\Tahoma2D DefaultGroupName=Tahoma2D AllowNoIcons=yes ;LicenseFile=license.rtf OutputBaseFilename=Tahoma2D-install-win Compression=lzma SolidCompression=yes ArchitecturesInstallIn64BitMode=x64 UninstallDisplayIcon={app}\{#MyAppExeName} [Languages] Name: "en"; MessagesFile: "compiler:Default.isl" [Tasks] Name: "desktopicon"; Description: "{cm:CreateDesktopIcon}"; GroupDescription: "{cm:AdditionalIcons}"; [Files] #include "files.iss" [Dirs] Name: "{code:GetStuffDir}\plugins"; Flags: uninsneveruninstall Name: "{code:GetStuffDir}\toonzfarm"; Flags: uninsneveruninstall Name: "{code:GetStuffDir}\projects"; Flags: uninsneveruninstall [Icons] Name: "{group}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}" Name: "{group}\{cm:UninstallProgram,{#MyAppName}}"; Filename: "{uninstallexe}" Name: "{commondesktop}\{#MyAppName}"; Filename: "{app}\{#MyAppExeName}"; Tasks: desktopicon [Run] Filename: "{app}\{#MyAppExeName}"; Description: "{cm:LaunchProgram,{#StringChange(MyAppName, '&', '&&')}}"; Flags: nowait postinstall skipifsilent [Registry] Root: HKLM; Subkey: "Software\Tahoma2D"; Flags: uninsdeletekeyifempty Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; Flags: uninsdeletekey Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DROOT"; ValueData: "{code:GetStuffDir}" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DPROJECTS"; ValueData: "{code:GetStuffDir}\projects" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DCONFIG"; ValueData: "{code:GetStuffDir}\config" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DPROFILES"; ValueData: "{code:GetStuffDir}\profiles" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DFXPRESETS"; ValueData: "{code:GetStuffDir}\fxs" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DLIBRARY"; ValueData: "{code:GetStuffDir}\library" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "TAHOMA2DSTUDIOPALETTE"; ValueData: "{code:GetStuffDir}\studiopalette" Root: HKLM; Subkey: "Software\Tahoma2D\Tahoma2D"; ValueType: string; ValueName: "FARMROOT"; ValueData: "" [Dirs] Name: {code:GetStuffDir}; Flags: uninsneveruninstall [CustomMessages] en.StuffDirPageTitle=Choose Destination Location for Stuff Folder en.StuffDirPageDescription=Select the folder where setup will install the Tahoma2D Stuff folder containing various setting files en.StuffDirPageLabel=Install the Tahoma2D Stuff folder to: en.OverwriteStuffCheckBoxLabel=Overwrite all setting files in the Stuff folder except user's personal settings [Code] var StuffDirPage: TInputDirWizardPage; OverwriteStuffCheckBox: TNewCheckBox; StuffRoot: String; procedure InitializeWizard; begin StuffDirPage := CreateInputDirPage(wpSelectDir, CustomMessage('StuffDirPageTitle'), CustomMessage('StuffDirPageDescription'), CustomMessage('StuffDirPageLabel'), False, ''); StuffDirPage.Add(''); if RegQueryStringValue(HKEY_LOCAL_MACHINE, 'Software\Tahoma2D\Tahoma2D', 'TAHOMA2DROOT', StuffRoot) then begin StuffDirPage.Values[0] := StuffRoot; end else begin StuffDirPage.Values[0] := 'C:\Tahoma2D stuff'; end; OverwriteStuffCheckBox := TNewCheckBox.Create(StuffDirPage); OverwriteStuffCheckBox.Caption := CustomMessage('OverwriteStuffCheckBoxLabel'); OverwriteStuffCheckBox.Parent := StuffDirPage.Surface; OverwriteStuffCheckBox.Top := ScaleY(70); OverwriteStuffCheckBox.Width := StuffDirPage.SurfaceWidth; OverwriteStuffCheckBox.Checked := True; end; function GetStuffDir(Param: String): String; begin Result := StuffDirPage.Values[0]; end; function IsOverwiteStuffCheckBoxChecked: Boolean; begin Result := OverwriteStuffCheckBox.Checked; end;