Browse Source

Bug fix: Wrong message shown in an installer when it cannot continue because previous installation/uninstallation was not completed.

Source commit: 1e6047c159047982b7f84e36859f9069b493a081
Martin Prikryl 9 years ago
parent
commit
cb713d1c57
1 changed files with 8 additions and 2 deletions
  1. 8 2
      deployment/winscpsetup.iss

+ 8 - 2
deployment/winscpsetup.iss

@@ -540,6 +540,11 @@ begin
   ShellExec('open', Url, '', '', SW_SHOWNORMAL, ewNoWait, ErrorCode);
 end;
 
+function IsRestartingApplicationsPage: Boolean;
+begin
+  Result := WizardForm.PreparingMemo.Visible;
+end;
+
 procedure OpenHelp;
 begin
   OpenBrowser('{#WebDocumentation}installation?page=' + IntToStr(WizardForm.CurPageID) + '&' + ExpandConstant('{#WebArguments}'));
@@ -1233,8 +1238,9 @@ begin
     else
   if CurPageID = wpPreparing then
   begin
-    // Are we at the "Restart applications?" screen
-    if WizardForm.PreparingLabel.Visible then
+    // Are we at the "Restart applications?" screen.
+    // If PreparingMemo is hidden, it's "installation/removal was not completed" screen
+    if IsRestartingApplicationsPage then
     begin
       WizardForm.PreparingLabel.Caption :=
         CustomMessage('ApplicationsFoundDragExt');