diff options
author | Simon Rozman <simon@rozman.si> | 2019-08-05 17:05:42 +0200 |
---|---|---|
committer | Jason A. Donenfeld <Jason@zx2c4.com> | 2019-08-05 20:12:19 +0200 |
commit | db7eccaff0c41d9fc6a2840ffa36794444c0d9b3 (patch) | |
tree | 1fe8491e9f4249ea90753a293ec6116af29f3c39 /installer | |
parent | elevate: consider ImageBaseAddress to be sufficiently stable (diff) | |
download | wireguard-windows-db7eccaff0c41d9fc6a2840ffa36794444c0d9b3.tar.xz wireguard-windows-db7eccaff0c41d9fc6a2840ffa36794444c0d9b3.zip |
installer: raise UI on MSI relaunch and add DO_NOT_LAUNCH override
Clicking on the MSI of an already installed WireGuard launches/raises
WireGuard UI now.
WireGuard UI launching can now also be disabled by invoking:
`msiexec /i wireguard...msi DO_NOT_LAUNCH=1`
Signed-off-by: Simon Rozman <simon@rozman.si>
Diffstat (limited to 'installer')
-rw-r--r-- | installer/wireguard.wxs | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/installer/wireguard.wxs b/installer/wireguard.wxs index c8a7d7c2..57ce388e 100644 --- a/installer/wireguard.wxs +++ b/installer/wireguard.wxs @@ -140,8 +140,15 @@ --> <CustomAction Id="LaunchApplication" HideTarget="yes" Impersonate="no" Execute="deferred" FileKey="wireguard.exe" ExeCommand="" Return="asyncNoWait" /> <InstallExecuteSequence> - <!-- TODO: this should not launch when msiexec is called with whatever flag means it shouldn't launch. --> - <Custom Action="LaunchApplication" After="PublishProduct">NOT Installed</Custom> + <Custom Action="LaunchApplication" Before="InstallFinalize">NOT Installed AND NOT DO_NOT_LAUNCH</Custom> + </InstallExecuteSequence> + + <!-- + Launch wireguard.exe on product reconfiguration (starting same MSI again) + --> + <CustomAction Id="LaunchApplicationAsOrdinaryUser" HideTarget="yes" FileKey="wireguard.exe" ExeCommand="" Return="asyncNoWait" /> + <InstallExecuteSequence> + <Custom Action="LaunchApplicationAsOrdinaryUser" After="InstallFinalize">Installed AND ProductState=5 AND NOT DO_NOT_LAUNCH</Custom> </InstallExecuteSequence> </Product> </Wix> |