1 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
2 ; NSIS installer script for vlc ;
\r
3 ; (http://nsis.sourceforge.net) ;
\r
4 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
6 !define PRODUCT_NAME "VLC media player"
\r
7 !define PRODUCT_VERSION '${VERSION}'
\r
8 !define PRODUCT_GROUP "VideoLAN"
\r
9 !define PRODUCT_PUBLISHER "VideoLAN Team"
\r
10 !define PRODUCT_WEB_SITE "http://www.videolan.org"
\r
11 !define PRODUCT_DIR_REGKEY "Software\VideoLAN\VLC"
\r
12 !define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
\r
13 !define PRODUCT_UNINST_ROOT_KEY "HKLM"
\r
14 !define PRODUCT_ID "{ea92ef52-afe4-4212-bacb-dfe9fca94cd6}"
\r
16 ;;;;;;;;;;;;;;;;;;;;;;;;;
\r
17 ; General configuration ;
\r
18 ;;;;;;;;;;;;;;;;;;;;;;;;;
\r
20 Name "${PRODUCT_GROUP} ${PRODUCT_NAME} ${PRODUCT_VERSION}"
\r
21 OutFile ..\vlc-${VERSION}-win32.exe
\r
22 InstallDir "$PROGRAMFILES\VideoLAN\VLC"
\r
23 InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" "Install_Dir"
\r
24 !ifdef NSIS_LZMA_COMPRESS_WHOLE
\r
27 SetCompressor /SOLID lzma
\r
29 ;ShowInstDetails show
\r
30 ;ShowUnInstDetails show
\r
31 SetOverwrite ifnewer
\r
37 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
38 ; NSIS Modern User Interface configuration ;
\r
39 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
41 ; MUI 1.67 compatible ------
\r
45 !define MUI_ABORTWARNING
\r
46 !define MUI_ICON "vlc48x48new.ico"
\r
47 !define MUI_UNICON "vlc48x48new.ico"
\r
48 !define MUI_COMPONENTSPAGE_SMALLDESC
\r
52 !define MUI_WELCOMEPAGE_TITLE_3LINES
\r
53 !insertmacro MUI_PAGE_WELCOME
\r
55 !insertmacro MUI_PAGE_LICENSE "COPYING.txt"
\r
57 !insertmacro MUI_PAGE_COMPONENTS
\r
59 !insertmacro MUI_PAGE_DIRECTORY
\r
61 !insertmacro MUI_PAGE_INSTFILES
\r
63 !define MUI_FINISHPAGE_RUN "$INSTDIR\vlc.exe"
\r
64 !define MUI_FINISHPAGE_SHOWREADME "$INSTDIR\NEWS.txt"
\r
65 !define MUI_FINISHPAGE_SHOWREADME_TEXT "View changelog"
\r
66 !define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
\r
67 !define MUI_FINISHPAGE_LINK "Visit the VideoLAN VLC media player Website"
\r
68 !define MUI_FINISHPAGE_LINK_LOCATION "http://www.videolan.org/vlc/"
\r
69 !define MUI_FINISHPAGE_NOREBOOTSUPPORT
\r
70 !insertmacro MUI_PAGE_FINISH
\r
73 !insertmacro MUI_UNPAGE_CONFIRM
\r
74 !insertmacro MUI_UNPAGE_COMPONENTS
\r
75 !insertmacro MUI_UNPAGE_INSTFILES
\r
76 !insertmacro MUI_UNPAGE_FINISH
\r
79 !insertmacro MUI_LANGUAGE "English" # first language is the default language
\r
80 !insertmacro MUI_LANGUAGE "French"
\r
81 !insertmacro MUI_LANGUAGE "German"
\r
82 !insertmacro MUI_LANGUAGE "Spanish"
\r
83 !insertmacro MUI_LANGUAGE "SimpChinese"
\r
84 !insertmacro MUI_LANGUAGE "TradChinese"
\r
85 !insertmacro MUI_LANGUAGE "Japanese"
\r
86 !insertmacro MUI_LANGUAGE "Korean"
\r
87 !insertmacro MUI_LANGUAGE "Italian"
\r
88 !insertmacro MUI_LANGUAGE "Dutch"
\r
89 !insertmacro MUI_LANGUAGE "Danish"
\r
90 !insertmacro MUI_LANGUAGE "Swedish"
\r
91 !insertmacro MUI_LANGUAGE "Norwegian"
\r
92 !insertmacro MUI_LANGUAGE "Finnish"
\r
93 !insertmacro MUI_LANGUAGE "Greek"
\r
94 !insertmacro MUI_LANGUAGE "Russian"
\r
95 !insertmacro MUI_LANGUAGE "Portuguese"
\r
96 !insertmacro MUI_LANGUAGE "Arabic"
\r
98 !insertmacro MUI_RESERVEFILE_LANGDLL
\r
101 !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS
\r
105 ;;;;;;;;;;;;;;;;;;;
\r
106 ; Extension lists ;
\r
107 ;;;;;;;;;;;;;;;;;;;
\r
109 !macro MacroAudioExtensions _action
\r
110 !insertmacro ${_action} ".a52"
\r
111 !insertmacro ${_action} ".aac"
\r
112 !insertmacro ${_action} ".ac3"
\r
113 !insertmacro ${_action} ".dts"
\r
114 !insertmacro ${_action} ".flac"
\r
115 !insertmacro ${_action} ".mka"
\r
116 !insertmacro ${_action} ".mp1"
\r
117 !insertmacro ${_action} ".mp2"
\r
118 !insertmacro ${_action} ".mp3"
\r
119 !insertmacro ${_action} ".ogg"
\r
120 !insertmacro ${_action} ".spx"
\r
121 !insertmacro ${_action} ".wav"
\r
122 !insertmacro ${_action} ".wma"
\r
125 !macro MacroVideoExtensions _action
\r
126 !insertmacro ${_action} ".asf"
\r
127 !insertmacro ${_action} ".avi"
\r
128 !insertmacro ${_action} ".divx"
\r
129 !insertmacro ${_action} ".dv"
\r
130 !insertmacro ${_action} ".m1v"
\r
131 !insertmacro ${_action} ".m2v"
\r
132 !insertmacro ${_action} ".mkv"
\r
133 !insertmacro ${_action} ".mov"
\r
134 !insertmacro ${_action} ".mp4"
\r
135 !insertmacro ${_action} ".mpeg"
\r
136 !insertmacro ${_action} ".mpeg1"
\r
137 !insertmacro ${_action} ".mpeg2"
\r
138 !insertmacro ${_action} ".mpeg4"
\r
139 !insertmacro ${_action} ".mpg"
\r
140 !insertmacro ${_action} ".ps"
\r
141 !insertmacro ${_action} ".ts"
\r
142 !insertmacro ${_action} ".ogm"
\r
143 !insertmacro ${_action} ".vob"
\r
144 !insertmacro ${_action} ".wmv"
\r
147 !macro MacroOtherExtensions _action
\r
148 !insertmacro ${_action} ".asx"
\r
149 !insertmacro ${_action} ".bin"
\r
150 !insertmacro ${_action} ".cue"
\r
151 !insertmacro ${_action} ".m3u"
\r
152 !insertmacro ${_action} ".pls"
\r
153 !insertmacro ${_action} ".vlc"
\r
156 !macro MacroAllExtensions _action
\r
157 !insertmacro MacroAudioExtensions ${_action}
\r
158 !insertmacro MacroVideoExtensions ${_action}
\r
159 !insertmacro MacroOtherExtensions ${_action}
\r
162 ;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
163 ; File type associations ;
\r
164 ;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
166 Function RegisterExtension
\r
167 ; back up old value for extension $R0 (eg. ".opt")
\r
168 ReadRegStr $1 HKCR "$R0" ""
\r
169 StrCmp $1 "" NoBackup
\r
170 StrCmp $1 "VLC$R0" "NoBackup"
\r
171 WriteRegStr HKCR "$R0" "VLC.backup" $1
\r
173 WriteRegStr HKCR "$R0" "" "VLC$R0"
\r
174 ReadRegStr $0 HKCR "VLC$R0" ""
\r
175 WriteRegStr HKCR "VLC$R0" "" "VLC media file"
\r
176 WriteRegStr HKCR "VLC$R0\shell" "" "Play"
\r
177 WriteRegStr HKCR "VLC$R0\shell\Play\command" "" '"$INSTDIR\vlc.exe" "%1"'
\r
178 WriteRegStr HKCR "VLC$R0\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
\r
181 Function un.RegisterExtension
\r
182 ;start of restore script
\r
183 ReadRegStr $1 HKCR "$R0" ""
\r
184 StrCmp $1 "VLC$R0" 0 NoOwn ; only do this if we own it
\r
185 ReadRegStr $1 HKCR "$R0" "VLC.backup"
\r
186 StrCmp $1 "" 0 Restore ; if backup="" then delete the whole key
\r
187 DeleteRegKey HKCR "$R0"
\r
190 WriteRegStr HKCR "$R0" "" $1
\r
191 DeleteRegValue HKCR "$R0" "VLC.backup"
\r
193 DeleteRegKey HKCR "VLC$R0" ;Delete key with association settings
\r
196 !macro RegisterExtensionSection EXT
\r
201 Call RegisterExtension
\r
206 !macro UnRegisterExtensionSection EXT
\r
209 Call un.RegisterExtension
\r
213 !macro WriteRegStrSupportedTypes EXT
\r
214 WriteRegStr HKCR Applications\vlc.exe\SupportedTypes ${EXT} ""
\r
217 ;;;;;;;;;;;;;;;;;;;;;;;;
\r
218 ; Context menu entries ;
\r
219 ;;;;;;;;;;;;;;;;;;;;;;;;
\r
221 !macro AddContextMenu EXT
\r
222 WriteRegStr HKCR ${EXT}\shell\PlayWithVLC "" "Play with VLC media player"
\r
223 WriteRegStr HKCR ${EXT}\shell\PlayWithVLC\command "" '$INSTDIR\vlc.exe --no-playlist-enqueue "%1"'
\r
225 WriteRegStr HKCR ${EXT}\shell\AddToPlaylistVLC "" "Add to VLC media player's Playlist"
\r
226 WriteRegStr HKCR ${EXT}\shell\AddToPlaylistVLC\command "" '$INSTDIR\vlc.exe --one-instance --playlist-enqueue "%1"'
\r
229 !macro DeleteContextMenu EXT
\r
230 DeleteRegKey HKCR ${EXT}\shell\PlayWithVLC
\r
231 DeleteRegKey HKCR ${EXT}\shell\AddToPlaylistVLC
\r
234 ;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
235 ; Delete prefs and cache ;
\r
236 ;;;;;;;;;;;;;;;;;;;;;;;;;;
\r
241 !define Index 'Line${__LINE__}'
\r
244 ; this will loop through all the logged users and "virtual" windows users
\r
245 ; (it looks like users are only present in HKEY_USERS when they are logged in)
\r
247 EnumRegKey $1 HKU "" $0
\r
248 StrCmp $1 "" "${Index}-End"
\r
250 ReadRegStr $2 HKU "$1\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" AppData
\r
251 StrCmp $2 "" "${Index}-Loop"
\r
253 Goto "${Index}-Loop"
\r
258 ;;;;;;;;;;;;;;;;;;;;;;
\r
259 ; Installer sections ;
\r
260 ;;;;;;;;;;;;;;;;;;;;;;
\r
262 Section "Media player (required)" SEC01
\r
264 SetShellVarContext all
\r
265 SetOutPath "$INSTDIR"
\r
268 File vlc.exe.manifest
\r
277 ; Add VLC to "recomended programs" for the following extensions
\r
278 WriteRegStr HKCR Applications\vlc.exe "" ""
\r
279 WriteRegStr HKCR Applications\vlc.exe "FriendlyAppName" "VLC media player"
\r
280 WriteRegStr HKCR Applications\vlc.exe\shell\Play "" "Play with VLC"
\r
281 WriteRegStr HKCR Applications\vlc.exe\shell\Play\command "" \
\r
282 '$INSTDIR\vlc.exe "%1"'
\r
283 !insertmacro MacroAllExtensions WriteRegStrSupportedTypes
\r
285 WriteRegStr HKCR "AudioCD\shell\PlayWithVLC" "" "Play with VLC media player"
\r
286 WriteRegStr HKCR "AudioCD\shell\PlayWithVLC\command" "" \
\r
287 "$INSTDIR\vlc.exe cdda:%1"
\r
288 WriteRegStr HKCR "DVD\shell\PlayWithVLC" "" "Play with VLC media player"
\r
289 WriteRegStr HKCR "DVD\shell\PlayWithVLC\command" "" \
\r
290 "$INSTDIR\vlc.exe dvd:%1"
\r
292 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayDVDMovieOnArrival" "VLCPlayDVDMovieOnArrival" ""
\r
293 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "Action" "Play DVD movie"
\r
294 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "DefaultIcon" '"$INSTDIR\vlc.exe",0'
\r
295 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "InvokeProgID" "VLC.DVDMovie"
\r
296 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "InvokeVerb" "play"
\r
297 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "Provider" "VideoLAN VLC media player"
\r
299 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayCDAudioOnArrival" "VLCPlayCDAudioOnArrival" ""
\r
300 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "Action" "Play CD audio"
\r
301 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "DefaultIcon" '"$INSTDIR\vlc.exe",0'
\r
302 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "InvokeProgID" "VLC.CDAudio"
\r
303 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "InvokeVerb" "play"
\r
304 WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "Provider" "VideoLAN VLC media player"
\r
305 WriteRegStr HKCR "VLC.DVDMovie" "" "VLC DVD Movie"
\r
306 WriteRegStr HKCR "VLC.DVDMovie\shell" "" "Play"
\r
307 WriteRegStr HKCR "VLC.DVDMovie\shell\Play\command" "" \
\r
308 '$INSTDIR\vlc.exe dvd:%1@1:0'
\r
309 WriteRegStr HKCR "VLC.DVDMovie\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
\r
310 WriteRegStr HKCR "VLC.CDAudio" "" "VLC CD Audio"
\r
311 WriteRegStr HKCR "VLC.CDAudio\shell" "" "Play"
\r
312 WriteRegStr HKCR "VLC.CDAudio\shell\Play\command" "" \
\r
313 '$INSTDIR\vlc.exe cdda:%1'
\r
314 WriteRegStr HKCR "VLC.CDAudio\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
\r
318 Section "Start Menu + Desktop Shortcut" SEC02
\r
320 CreateDirectory "$SMPROGRAMS\VideoLAN"
\r
321 CreateShortCut "$SMPROGRAMS\VideoLAN\VLC media player.lnk" \
\r
322 "$INSTDIR\vlc.exe" "--intf wx --wx-embed"
\r
323 CreateShortCut "$SMPROGRAMS\VideoLAN\VLC media player (alt).lnk" \
\r
324 "$INSTDIR\vlc.exe" "--intf wx --no-wx-embed"
\r
325 CreateShortCut "$SMPROGRAMS\VideoLAN\VLC media player (skins).lnk" \
\r
326 "$INSTDIR\vlc.exe" "--intf skins"
\r
327 CreateShortCut "$SMPROGRAMS\VideoLAN\Reset VLC defaults and quit.lnk" \
\r
328 "$INSTDIR\vlc.exe" "--reset-config --reset-plugins-cache --save-config vlc:quit "
\r
329 CreateShortCut "$DESKTOP\VLC media player.lnk" \
\r
330 "$INSTDIR\vlc.exe" "--intf wx"
\r
331 WriteIniStr "$INSTDIR\${PRODUCT_NAME}.url" "InternetShortcut" "URL" \
\r
332 "${PRODUCT_WEB_SITE}"
\r
333 CreateShortCut "$SMPROGRAMS\VideoLAN\${PRODUCT_NAME} Website.lnk" \
\r
334 "$INSTDIR\${PRODUCT_NAME}.url"
\r
335 WriteIniStr "$INSTDIR\Documentation.url" "InternetShortcut" "URL" \
\r
336 "${PRODUCT_WEB_SITE}/doc/"
\r
337 CreateShortCut "$SMPROGRAMS\VideoLAN\Documentation.lnk" \
\r
338 "$INSTDIR\Documentation.url"
\r
341 Section /o "Mozilla plugin" SEC03
\r
345 ; doesn't work. bug in mozilla/mozilla firefox or moz documentation (xpt file isn't loaded)
\r
346 ; see mozilla bugs 184506 and 159445
\r
347 ;!define Moz "SOFTWARE\MozillaPlugins\@videolan.org/vlc,version=${VERSION}"
\r
348 ;WriteRegStr HKLM ${Moz} "Description" "VideoLAN VLC plugin for Mozilla"
\r
349 ;WriteRegStr HKLM ${Moz} "Path" "$INSTDIR\mozilla\npvlc.dll"
\r
350 ;WriteRegStr HKLM ${Moz} "Product" "VLC media player"
\r
351 ;WriteRegStr HKLM ${Moz} "Vendor" "VideoLAN"
\r
352 ;WriteRegStr HKLM ${Moz} "Version" "${VERSION}"
\r
353 ;WriteRegStr HKLM ${Moz} "XPTPath" "$INSTDIR\mozilla\vlcintf.xpt"
\r
359 !define Index 'Line${__LINE__}'
\r
365 EnumRegKey $R0 HKLM "SOFTWARE\Mozilla" "$R1"
\r
366 StrCmp $R0 "" "${Index}-End"
\r
368 ReadRegStr $R2 HKLM "SOFTWARE\Mozilla\$R0\Extensions" "Plugins"
\r
369 StrCmp $R2 "" "${Index}-Loop" ""
\r
371 CopyFiles "$INSTDIR\mozilla\*" "$R2"
\r
372 Goto "${Index}-Loop"
\r
379 Section /o "ActiveX plugin" SEC04
\r
381 SetOutPath "$INSTDIR"
\r
382 File activex\axvlc.dll
\r
383 RegDLL "$INSTDIR\axvlc.dll"
\r
386 Section "Context Menus" SEC05
\r
388 !insertmacro MacroAllExtensions AddContextMenu
\r
389 !insertmacro AddContextMenu "Folder"
\r
392 SectionGroup "File type associations" SEC06
\r
393 SectionGroup "Audio Files"
\r
394 !insertmacro MacroAudioExtensions RegisterExtensionSection
\r
396 SectionGroup "Video Files"
\r
397 !insertmacro MacroVideoExtensions RegisterExtensionSection
\r
399 SectionGroup "Other"
\r
400 !insertmacro MacroOtherExtensions RegisterExtensionSection
\r
404 Section /o "Delete preferences and cache" SEC07
\r
405 !insertmacro delprefs
\r
408 ; Installer section descriptions
\r
409 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
\r
410 !insertmacro MUI_DESCRIPTION_TEXT ${SEC01} \
\r
411 "The media player itself"
\r
412 !insertmacro MUI_DESCRIPTION_TEXT ${SEC02} \
\r
413 "Adds icons to your start menu and your desktop for easy access"
\r
414 !insertmacro MUI_DESCRIPTION_TEXT ${SEC03} \
\r
415 "The VLC Mozilla and Mozilla Firefox plugin"
\r
416 !insertmacro MUI_DESCRIPTION_TEXT ${SEC04} \
\r
417 "The VLC ActiveX plugin"
\r
418 !insertmacro MUI_DESCRIPTION_TEXT ${SEC05} \
\r
419 "Add context menu items ('Play With VLC' and 'Add To VLC's Playlist')"
\r
420 !insertmacro MUI_DESCRIPTION_TEXT ${SEC06} \
\r
421 "Sets VLC media player as the default application for the specified file type"
\r
422 !insertmacro MUI_DESCRIPTION_TEXT ${SEC07} \
\r
423 "Deletes VLC media player preferences and cache files leftover from previous installations"
\r
424 !insertmacro MUI_FUNCTION_DESCRIPTION_END
\r
427 ReadRegStr $R0 ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
431 MessageBox MB_YESNO|MB_ICONEXCLAMATION \
\r
432 "VLC media player has already been installed. $\nDo you want to remove \
\r
433 the previous version before installing $(^Name) ?" \
\r
436 ;Run the uninstaller
\r
439 ExecWait '$R0 _?=$INSTDIR' ;Do not copy the uninstaller to a temp file
\r
441 !insertmacro MUI_LANGDLL_DISPLAY
\r
445 WriteUninstaller "$INSTDIR\uninstall.exe"
\r
446 WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "InstallDir" $INSTDIR
\r
447 WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "Version" "${VERSION}"
\r
448 WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$INSTDIR\vlc.exe"
\r
450 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
451 "DisplayName" "$(^Name)"
\r
452 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
453 "UninstallString" "$INSTDIR\uninstall.exe"
\r
454 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
455 "DisplayIcon" "$INSTDIR\vlc.exe"
\r
456 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
457 "DisplayVersion" "${PRODUCT_VERSION}"
\r
458 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
459 "URLInfoAbout" "${PRODUCT_WEB_SITE}"
\r
460 WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
\r
461 "Publisher" "${PRODUCT_PUBLISHER}"
\r
464 ;;;;;;;;;;;;;;;;;;;;;;;;
\r
465 ; Uninstaller sections ;
\r
466 ;;;;;;;;;;;;;;;;;;;;;;;;
\r
468 Section "Uninstall" SEC91
\r
470 SetShellVarContext all
\r
472 !insertmacro MacroAllExtensions DeleteContextMenu
\r
473 !insertmacro MacroAllExtensions UnRegisterExtensionSection
\r
474 !insertmacro DeleteContextMenu "Folder"
\r
476 UnRegDLL "$INSTDIR\axvlc.dll"
\r
477 Delete /REBOOTOK "$INSTDIR\axvlc.dll"
\r
479 ;remove mozilla plugin
\r
484 !define Index 'Line${__LINE__}'
\r
490 EnumRegKey $R0 HKLM "SOFTWARE\Mozilla" "$R1"
\r
491 StrCmp $R0 "" "${Index}-End"
\r
493 ReadRegStr $R2 HKLM "SOFTWARE\Mozilla\$R0\Extensions" "Plugins"
\r
494 StrCmp $R2 "" "${Index}-Loop" ""
\r
496 Delete "$R2\vlcintf.xpt"
\r
497 Delete "$R2\npvlc.dll"
\r
498 Goto "${Index}-Loop"
\r
503 RMDir "$SMPROGRAMS\VideoLAN"
\r
504 RMDir /r $SMPROGRAMS\VideoLAN
\r
506 DeleteRegKey HKLM Software\VideoLAN
\r
508 DeleteRegKey HKCR Applications\vlc.exe
\r
509 DeleteRegKey HKCR AudioCD\shell\PlayWithVLC
\r
510 DeleteRegKey HKCR DVD\shell\PlayWithVLC
\r
511 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayDVDMovieOnArrival" "VLCPlayDVDMovieOnArrival"
\r
512 DeleteRegKey HKLM Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival
\r
513 DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayCDAudioOnArrival" "VLCPlayCDAudioOnArrival"
\r
514 DeleteRegKey HKLM Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival
\r
515 DeleteRegKey HKCR "VLC.MediaFile"
\r
517 DeleteRegKey HKLM \
\r
518 "SOFTWARE\MozillaPlugins\@videolan.org/vlc,version=${VERSION}"
\r
520 DeleteRegKey HKLM \
\r
521 "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
\r
523 Delete "$DESKTOP\VLC media player.lnk"
\r
525 DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
\r
526 DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
\r
530 Section /o "un.Delete preferences and cache" SEC92
\r
531 !insertmacro delprefs
\r
534 ; Uninstaller section descriptions
\r
535 !insertmacro MUI_UNFUNCTION_DESCRIPTION_BEGIN
\r
536 !insertmacro MUI_DESCRIPTION_TEXT ${SEC91} \
\r
537 "Uninstall VLC media player and all its components"
\r
538 !insertmacro MUI_DESCRIPTION_TEXT ${SEC92} \
\r
539 "Deletes VLC media player preferences and cache files"
\r
540 !insertmacro MUI_UNFUNCTION_DESCRIPTION_END
\r
542 ;Function un.onUninstSuccess
\r
544 ; MessageBox MB_ICONINFORMATION|MB_OK \
\r
545 ; "$(^Name) was successfully removed from your computer."
\r
549 !insertmacro MUI_LANGDLL_DISPLAY
\r