For such entries the archive is downloaded to {tmp}\_isetup\<randomdir>\<destname> using a TDownloadWizardPage, as the first step of PrepareToInstall. Supports verification.
On success the entries' SourceFilename is updated to the temp file, the download flag is removed and also DestName and verification. Áfter that the rest (PreviousInstallCompleted, RegisterResourcesWithRestartManager, and installation) works normally and required no changes.
On error the problem is displayed by the ready page. Also didn't require changes, except for an extract on BaseName display.
Todo:
-Rename CodeDownloadFiles.iss since there's no [Code] in it anymore.
-Offer Abort/Retry when a download fails? Or even Ignore somehow?
-Let the user choose if it should show BaseNames or URLs while downloading with a new directive? Both for archives and files.
-Document
Also always set DisableFsRedir to False in InternalExtractTemporaryFile and DownloadTemporaryFile just like it already does for everything else working on the temp dir.
Show has a BringToFront call that we don't need. Changing Visible from False to True already brings the window to the front when not minimized. And when it is minimized, we don't want it becoming the active window.
This works around the same VCL issue as in preceding commits, where the Forms unit's WM_ACTIVATEAPP handler sets FAppIconic=False even though the window may still be minimized, which causes the next Application.Restore call to be a no-op.
Works around VCL bug. If Application.BringToFront is called while the app is minimized, the Forms unit's WM_ACTIVATEAPP handler inexplicably sets FAppIconic=False, which causes the next Application.Restore call to be a no-op.
Mostly done, I think. Still need to actually remove shWindowVisible etc. Still some Application.Handle references that need to be cleaned out. Still need to update help.
TMainForm still exists, but is no longer a form. Good enough for now.
With Application.MainFormOnTaskBar=True, we now have a working taskbar thumbnail and proper minimize/restore animations. Finally.
Previously, square images could appear horizontally stretched or squished, depending on the font size.
This change does mean that if non-square image sizes were used to work around the problem, the images will now have to be resized.
Previously, when multiple images were specified, the control was left at its default non-square 55x58 size, causing vertical stretching if square image sizes like 55x55 were used.
Report: https://groups.google.com/g/innosetup/c/9IB8v14MoKI
Encryption itself is unchanged by this commit except that the key is now derived from the password only once. So it still uses SHA-256 for this.
The next step is changing this to a proper KDF, by changing the implementation of GenerateEncryptionKey and the TSetupEncryptionKey type.