Enhance Windows installer configuration and add license file

- Updated the WiX configuration in build_windows.py to include required properties for the WixUI_InstallDir dialog.
- Changed the UI reference from WixUI_Minimal to WixUI_InstallDir for improved installation experience.
- Added custom branding images for the installer UI using WixVariable for background and banner images.
- Introduced a new license.rtf file containing the MIT License for the WebDrop Bridge project.
- Updated binary resources for background and banner images.
This commit is contained in:
claudi 2026-02-19 15:09:08 +01:00
parent 302ec15e15
commit a20f703554
8 changed files with 2914 additions and 2887 deletions

View file

@ -21,6 +21,7 @@ Usage:
import sys
import os
from typing import Optional
# Fix Unicode output on Windows BEFORE any other imports
if sys.platform == "win32":
@ -309,15 +310,19 @@ class WindowsBuilder:
<Package InstallerVersion="200" Compressed="yes" InstallScope="perMachine" Platform="x64" />
<Media Id="1" Cabinet="WebDropBridge.cab" EmbedCab="yes" />
<!-- Required property for WixUI_InstallDir dialog set -->
<Property Id="WIXUI_INSTALLDIR" Value="INSTALLFOLDER" />
<!-- Application Icon -->
<Icon Id="AppIcon.ico" SourceFile="$(var.ResourcesDir)\\icons\\app.ico" />
<!-- Embedded branding images for installer UI -->
<Binary Id="BannerBmp" SourceFile="$(var.ResourcesDir)\\icons\\banner.bmp" />
<Binary Id="DialogBmp" SourceFile="$(var.ResourcesDir)\\icons\\background.bmp" />
<!-- Custom branding for InstallDir dialog set -->
<WixVariable Id="WixUIDialogBmp" Value="$(var.ResourcesDir)\\icons\\background.bmp" />
<WixVariable Id="WixUIBannerBmp" Value="$(var.ResourcesDir)\\icons\\banner.bmp" />
<WixVariable Id="WixUILicenseRtf" Value="$(var.ResourcesDir)\\license.rtf" />
<!-- Installation UI dialogs -->
<UIRef Id="WixUI_Minimal" />
<UIRef Id="WixUI_InstallDir" />
<UIRef Id="WixUI_ErrorProgressText" />
<Feature Id="ProductFeature" Title="WebDrop Bridge" Level="1">
@ -382,7 +387,7 @@ class WindowsBuilder:
print(f" Created WiX source: {wix_file}")
return True
def _generate_file_elements(self, folder: Path, parent_dir_ref: str, parent_rel_path: str, indent: int = 8, file_counter: dict = None) -> str:
def _generate_file_elements(self, folder: Path, parent_dir_ref: str, parent_rel_path: str, indent: int = 8, file_counter: Optional[dict] = None) -> str:
"""Generate WiX File elements for all files in a folder.
Args: