diff nsis/gvim.nsi @ 24565:138e9caf4a7a v8.2.2822

patch 8.2.2822: MS-Windows: unnessarily loading libraries when unregistering Commit: https://github.com/vim/vim/commit/4a22897591dc8ff64560bef693af49f171faf557 Author: Bram Moolenaar <Bram@vim.org> Date: Sat May 1 22:41:39 2021 +0200 patch 8.2.2822: MS-Windows: unnessarily loading libraries when unregistering Problem: MS-Windows: unnessarily loading libraries when unregistering OLE. Solution: Also skip loading libraries when invoked with "-unregister". Run Vim for README.txt with user privileges.
author Bram Moolenaar <Bram@vim.org>
date Sat, 01 May 2021 22:45:04 +0200
parents a934526dacd2
children d5b5267595c5
line wrap: on
line diff
--- a/nsis/gvim.nsi
+++ b/nsis/gvim.nsi
@@ -119,9 +119,9 @@ RequestExecutionLevel highest
 
 !define MUI_COMPONENTSPAGE_SMALLDESC
 !define MUI_LICENSEPAGE_CHECKBOX
-!define MUI_FINISHPAGE_RUN                 "$0\gvim.exe"
+!define MUI_FINISHPAGE_RUN
+!define MUI_FINISHPAGE_RUN_FUNCTION        LaunchApplication
 !define MUI_FINISHPAGE_RUN_TEXT            $(str_show_readme)
-!define MUI_FINISHPAGE_RUN_PARAMETERS      "-R $\"$0\README.txt$\""
 
 # This adds '\Vim' to the user choice automagically.  The actual value is
 # obtained below with CheckOldVim.
@@ -300,6 +300,11 @@ Function CheckOldVim
   Exch $0  # put $0 on top of stack, restore $0 to original value
 FunctionEnd
 
+Function LaunchApplication
+   SetOutPath $0
+   ShellExecAsUser::ShellExecAsUser "" "$0\gvim.exe" "-R $"$0\README.txt$""
+FunctionEnd
+
 ##########################################################
 Section "$(str_section_old_ver)" id_section_old_ver
 	SectionIn 1 2 3 RO