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,