From 5bb09f7c038201a68f904434c8bd90209fabb65e Mon Sep 17 00:00:00 2001 From: jkarasti Date: Tue, 29 Oct 2024 18:56:56 +0200 Subject: [PATCH] Change: Wrap installer ui related things in a `UI` element --- install/windows/build-wxs.py | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/install/windows/build-wxs.py b/install/windows/build-wxs.py index f94a184..f03e1ab 100644 --- a/install/windows/build-wxs.py +++ b/install/windows/build-wxs.py @@ -152,10 +152,6 @@ def main(): Id="ARPURLINFOABOUT", Value="https://freedom.press", ) - ET.SubElement( - package_el, "ui:WixUI", Id="WixUI_InstallDir", InstallDirectory="INSTALLFOLDER" - ) - ET.SubElement(package_el, "UIRef", Id="WixUI_ErrorProgressText") ET.SubElement( package_el, "WixVariable", @@ -175,6 +171,13 @@ def main(): DowngradeErrorMessage="A newer version of [ProductName] is already installed. If you are sure you want to downgrade, remove the existing installation via Programs and Features.", ) + # Add The UI element + ui_el = ET.SubElement(package_el, "UI") + ET.SubElement( + ui_el, "ui:WixUI", Id="WixUI_InstallDir", InstallDirectory="INSTALLFOLDER" + ) + ET.SubElement(ui_el, "UIRef", Id="WixUI_ErrorProgressText") + # Add the ProgramMenuFolder StandardDirectory programmenufolder_el = ET.SubElement( package_el,