Fix running application detection for uninstalling.

This commit is contained in:
Julien Wadel 2022-07-04 11:40:09 +02:00
parent 865b14f4eb
commit 9b52bcfdb1
3 changed files with 6 additions and 6 deletions

View file

@ -21,6 +21,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Fixes
- Display name are based on friends (coming from local or LDAP server) and caller address only.
- Running application detection for uninstalling.
## 4.4.7 - 2022-07-01

View file

@ -906,10 +906,9 @@ SectionEnd
; "Program Files" for AllUsers, "My Documents" for JustMe...
Function .onInit
FindWindow $0 "gdkWindowToplevel" "@CPACK_PACKAGE_NAME@"
FindWindow $1 "Qt5QWindowOwnDCIcon" "@CPACK_PACKAGE_NAME@"
StrCmp "$0$1" "00" notRunning
MessageBox MB_OK|MB_ICONEXCLAMATION "@CPACK_PACKAGE_NAME@ is running. Please close it first and restart the installation." /SD IDOK
FindWindow $0 "" "@CPACK_PACKAGE_NAME@"
StrCmp "$0" "0" notRunning
MessageBox MB_OK|MB_ICONEXCLAMATION "@CPACK_PACKAGE_NAME@ is running. Please close it first from the application menu and restart the installation." /SD IDOK
Abort
notRunning:

View file

@ -1,6 +1,6 @@
FindWindow $0 "gdkWindowToplevel" "@APPLICATION_NAME@"
FindWindow $0 "" "@APPLICATION_NAME@"
StrCmp $0 0 notRunningInUninstall
MessageBox MB_OK|MB_ICONEXCLAMATION "@APPLICATION_NAME@ is running. Please close it first and restart the uninstall program." /SD IDOK
MessageBox MB_OK|MB_ICONEXCLAMATION "@APPLICATION_NAME@ is running. Please close it first from the application menu and restart the uninstall program." /SD IDOK
Abort
notRunningInUninstall: