]> git.sesse.net Git - vlc/blob - extras/package/win32/vlc.win32.nsi.in
6afecd4b676894d019f340654655978e83a41b78
[vlc] / extras / package / win32 / vlc.win32.nsi.in
1 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
2 ; NSIS installer script for vlc ;
3 ; (http://nsis.sourceforge.net) ;
4 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
5
6 !include "languages\declaration.nsh"
7
8 !define PRODUCT_NAME "VLC media player"
9 !define VERSION @VERSION@
10 !define PRODUCT_VERSION @VERSION@
11 !define PRODUCT_GROUP "VideoLAN"
12 !define PRODUCT_PUBLISHER "VideoLAN Team"
13 !define PRODUCT_WEB_SITE "http://www.videolan.org"
14 !define PRODUCT_DIR_REGKEY "Software\VideoLAN\VLC"
15 !define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
16 !define PRODUCT_UNINST_ROOT_KEY "HKLM"
17 !define PRODUCT_ID "{ea92ef52-afe4-4212-bacb-dfe9fca94cd6}"
18
19 !define MUI_LANGDLL_REGISTRY_ROOT "HKLM"
20 !define MUI_LANGDLL_REGISTRY_KEY "${PRODUCT_DIR_REGKEY}"
21 !define MUI_LANGDLL_REGISTRY_VALUENAME "Language"
22
23 @BUILD_ACTIVEX_TRUE@ !define INSTALL_ACTIVEX
24 @BUILD_MOZILLA_TRUE@ !define INSTALL_MOZILLA
25
26 @FILE_LIBVLCCORE_DLL@
27 @FILE_LIBVLC_DLL@
28
29 ;;;;;;;;;;;;;;;;;;;;;;;;;
30 ; General configuration ;
31 ;;;;;;;;;;;;;;;;;;;;;;;;;
32
33 Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
34 OutFile ..\vlc-${VERSION}-win32.exe
35 InstallDir "$PROGRAMFILES\VideoLAN\VLC"
36 InstallDirRegKey HKLM "${PRODUCT_DIR_REGKEY}" ""
37 !ifdef NSIS_LZMA_COMPRESS_WHOLE
38 SetCompressor lzma
39 !else
40 SetCompressor /SOLID lzma
41 !endif
42
43 SetOverwrite ifnewer
44 CRCCheck on
45 BrandingText "${PRODUCT_GROUP} ${PRODUCT_NAME}"
46
47 InstType $Name_InstTypeRecommended
48 InstType $Name_InstTypeMinimum
49 InstType $Name_InstTypeFull
50
51 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
52 ; NSIS Modern User Interface configuration ;
53 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
54
55 ; MUI 1.67 compatible ------
56   !include "MUI.nsh"
57
58 ; MUI Settings
59   !define MUI_ABORTWARNING
60   !define MUI_ICON "vlc.ico"
61   !define MUI_UNICON "vlc.ico"
62   !define MUI_COMPONENTSPAGE_SMALLDESC
63
64 ; Installer pages
65   ; Welcome page
66     !define MUI_WELCOMEPAGE_TITLE_3LINES
67     !insertmacro MUI_PAGE_WELCOME
68   ; License page
69     !insertmacro MUI_PAGE_LICENSE "COPYING.txt"
70   ; Components page
71     !insertmacro MUI_PAGE_COMPONENTS
72   ; Directory page
73     !insertmacro MUI_PAGE_DIRECTORY
74   ; Instfiles page
75     !insertmacro MUI_PAGE_INSTFILES
76   ; Finish page
77     !define MUI_FINISHPAGE_RUN "$INSTDIR\vlc.exe"
78     !define MUI_FINISHPAGE_SHOWREADME "$INSTDIR\README.txt"
79     !define MUI_FINISHPAGE_SHOWREADME_NOTCHECKED
80     !define MUI_FINISHPAGE_LINK $Link_VisitWebsite
81     !define MUI_FINISHPAGE_LINK_LOCATION "http://www.videolan.org/vlc/"
82     !define MUI_FINISHPAGE_NOREBOOTSUPPORT
83     !insertmacro MUI_PAGE_FINISH
84
85 ; Uninstaller pages
86     !insertmacro MUI_UNPAGE_CONFIRM
87     !insertmacro MUI_UNPAGE_COMPONENTS
88     !insertmacro MUI_UNPAGE_INSTFILES
89     !insertmacro MUI_UNPAGE_FINISH
90
91 ; Language files
92   !insertmacro MUI_LANGUAGE "English" # first language is the default language
93   !insertmacro MUI_LANGUAGE "French"
94   !insertmacro MUI_LANGUAGE "German"
95   !insertmacro MUI_LANGUAGE "Spanish"
96   !insertmacro MUI_LANGUAGE "SimpChinese"
97   !insertmacro MUI_LANGUAGE "TradChinese"
98   !insertmacro MUI_LANGUAGE "Japanese"
99   !insertmacro MUI_LANGUAGE "Korean"
100   !insertmacro MUI_LANGUAGE "Italian"
101   !insertmacro MUI_LANGUAGE "Dutch"
102   !insertmacro MUI_LANGUAGE "Danish"
103   !insertmacro MUI_LANGUAGE "Swedish"
104   !insertmacro MUI_LANGUAGE "Norwegian"
105   !insertmacro MUI_LANGUAGE "Finnish"
106   !insertmacro MUI_LANGUAGE "Greek"
107   !insertmacro MUI_LANGUAGE "Russian"
108   !insertmacro MUI_LANGUAGE "Portuguese"
109   !insertmacro MUI_LANGUAGE "PortugueseBR"
110   !insertmacro MUI_LANGUAGE "Arabic"
111   !insertmacro MUI_LANGUAGE "Polish"
112   !insertmacro MUI_LANGUAGE "Romanian"
113   !insertmacro MUI_LANGUAGE "Slovak"
114   !insertmacro MUI_LANGUAGE "Czech"
115   !insertmacro MUI_LANGUAGE "Hungarian"
116   !insertmacro MUI_LANGUAGE "Catalan"
117   !insertmacro MUI_LANGUAGE "Bulgarian"
118
119 ; Reserve files for solid compression
120   !insertmacro MUI_RESERVEFILE_LANGDLL
121   !insertmacro MUI_RESERVEFILE_INSTALLOPTIONS
122
123 ; MUI end ------
124
125 ;;;;;;;;;;;;;;;;;;;;;;;
126 ; Macro and Functions ;
127 ;;;;;;;;;;;;;;;;;;;;;;;
128
129 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
130 ; 1. File type associations ;
131 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
132
133 ;; Function that register one extension for VLC
134 Function RegisterExtension
135   ; back up old value for extension $R0 (eg. ".opt")
136   ReadRegStr $1 HKCR "$R0" ""
137   StrCmp $1 "" NoBackup
138     StrCmp $1 "VLC$R0" "NoBackup"
139     WriteRegStr HKCR "$R0" "VLC.backup" $1
140 NoBackup:
141   WriteRegStr HKCR "$R0" "" "VLC$R0"
142   ReadRegStr $0 HKCR "VLC$R0" ""
143   WriteRegStr HKCR "VLC$R0" "" "VLC media file ($R0)"
144   WriteRegStr HKCR "VLC$R0\shell" "" "Open"
145   WriteRegStr HKCR "VLC$R0\shell\Open" "" $ShellAssociation_Play
146   WriteRegStr HKCR "VLC$R0\shell\Open\command" "" '"$INSTDIR\vlc.exe" --started-from-file "%1"'
147   WriteRegStr HKCR "VLC$R0\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
148
149 ;;; Vista Only part
150   ; Vista detection
151   ReadRegStr $R1 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
152   StrCpy $R2 $R1 3
153   StrCmp $R2 '6.0' ForVista ToEnd
154 ForVista:
155   WriteRegStr HKLM "Software\Clients\Media\VLC\Capabilities\FileAssociations" "$R0" "VLC$R0"
156
157 ToEnd:
158 FunctionEnd
159
160 ;; Function that removes one extension that VLC owns.
161 Function un.RegisterExtension
162   ;start of restore script
163   ReadRegStr $1 HKCR "$R0" ""
164   StrCmp $1 "VLC$R0" 0 NoOwn ; only do this if we own it
165     ; Read the old value from Backup
166     ReadRegStr $1 HKCR "$R0" "VLC.backup"
167     StrCmp $1 "" 0 Restore ; if backup="" then delete the whole key
168       DeleteRegKey HKCR "$R0"
169     Goto NoOwn
170 Restore:
171       WriteRegStr HKCR "$R0" "" $1
172       DeleteRegValue HKCR "$R0" "VLC.backup"
173 NoOwn:
174     DeleteRegKey HKCR "VLC$R0" ;Delete key with association settings
175     DeleteRegKey HKLM "Software\Clients\Media\VLC\Capabilities\FileAssociations\VLC$R0" ; for vista
176 FunctionEnd
177
178 !macro RegisterExtensionSection EXT
179   Section ${EXT}
180     SectionIn 1 3
181     Push $R0
182     StrCpy $R0 ${EXT}
183     Call RegisterExtension
184     Pop $R0
185   SectionEnd
186 !macroend
187
188 !macro UnRegisterExtensionSection EXT
189   Push $R0
190   StrCpy $R0 ${EXT}
191   Call un.RegisterExtension
192   Pop $R0
193 !macroend
194
195 !macro WriteRegStrSupportedTypes EXT
196   WriteRegStr HKCR Applications\vlc.exe\SupportedTypes ${EXT} ""
197 !macroend
198
199 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
200 ; Extension lists  Macros                    ;
201 ; Those macros calls the previous functions  ;
202 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
203
204 !macro MacroAudioExtensions _action
205   !insertmacro ${_action} ".a52"
206   !insertmacro ${_action} ".aac"
207   !insertmacro ${_action} ".ac3"
208   !insertmacro ${_action} ".aob"
209   !insertmacro ${_action} ".dts"
210   !insertmacro ${_action} ".flac"
211   !insertmacro ${_action} ".m4a"
212   !insertmacro ${_action} ".m4p"
213   !insertmacro ${_action} ".mka"
214   !insertmacro ${_action} ".mod"
215   !insertmacro ${_action} ".mp1"
216   !insertmacro ${_action} ".mp2"
217   !insertmacro ${_action} ".mp3"
218   !insertmacro ${_action} ".oma"
219   !insertmacro ${_action} ".oga"
220   !insertmacro ${_action} ".spx"
221   !insertmacro ${_action} ".wav"
222   !insertmacro ${_action} ".wma"
223   !insertmacro ${_action} ".wv"
224   !insertmacro ${_action} ".xm"
225 !macroend
226
227 !macro MacroVideoExtensions _action
228   !insertmacro ${_action} ".asf"
229   !insertmacro ${_action} ".avi"
230   !insertmacro ${_action} ".divx"
231   !insertmacro ${_action} ".dv"
232   !insertmacro ${_action} ".flv"
233   !insertmacro ${_action} ".gxf"
234   !insertmacro ${_action} ".m1v"
235   !insertmacro ${_action} ".m2v"
236   !insertmacro ${_action} ".m2ts"
237   !insertmacro ${_action} ".m4v"
238   !insertmacro ${_action} ".mkv"
239   !insertmacro ${_action} ".mov"
240   !insertmacro ${_action} ".mp4"
241   !insertmacro ${_action} ".mpeg"
242   !insertmacro ${_action} ".mpeg1"
243   !insertmacro ${_action} ".mpeg2"
244   !insertmacro ${_action} ".mpeg4"
245   !insertmacro ${_action} ".mpg"
246   !insertmacro ${_action} ".mts"
247   !insertmacro ${_action} ".mxf"
248   !insertmacro ${_action} ".nuv"
249   !insertmacro ${_action} ".ogg"
250   !insertmacro ${_action} ".ogm"
251   !insertmacro ${_action} ".ogx"
252   !insertmacro ${_action} ".ogv"
253   !insertmacro ${_action} ".rmvb"
254   !insertmacro ${_action} ".ts"
255   !insertmacro ${_action} ".vob"
256   !insertmacro ${_action} ".wmv"
257 !macroend
258
259 !macro MacroOtherExtensions _action
260   !insertmacro ${_action} ".asx"
261   !insertmacro ${_action} ".bin"
262   !insertmacro ${_action} ".cue"
263   !insertmacro ${_action} ".m3u"
264   !insertmacro ${_action} ".pls"
265   !insertmacro ${_action} ".vlc"
266   !insertmacro ${_action} ".xspf"
267 !macroend
268
269 ; One macro to rule them all
270 !macro MacroAllExtensions _action
271   !insertmacro MacroAudioExtensions ${_action}
272   !insertmacro MacroVideoExtensions ${_action}
273   !insertmacro MacroOtherExtensions ${_action}
274 !macroend
275
276 ;;;;;;;;;;;;;;;;;;;;;;;;;;;
277 ; 2. Context menu entries ;
278 ;;;;;;;;;;;;;;;;;;;;;;;;;;;
279
280 ; Generic function for adding the context menu for one ext.
281 !macro AddContextMenuExt EXT
282   WriteRegStr HKCR ${EXT}\shell\PlayWithVLC "" $ContextMenuEntry_PlayWith
283   WriteRegStr HKCR ${EXT}\shell\PlayWithVLC\command "" '"$INSTDIR\vlc.exe" --started-from-file --no-playlist-enqueue "%1"'
284
285   WriteRegStr HKCR ${EXT}\shell\AddToPlaylistVLC "" $ContextMenuEntry_AddToPlaylist
286   WriteRegStr HKCR ${EXT}\shell\AddToPlaylistVLC\command "" '"$INSTDIR\vlc.exe" --started-from-file --playlist-enqueue "%1"'
287 !macroend
288
289 !macro AddContextMenu EXT
290   Push $R0
291   ReadRegStr $R0 HKCR ${EXT} ""
292   !insertmacro AddContextMenuExt $R0
293   Pop $R0
294 !macroend
295
296 !macro DeleteContextMenuExt EXT
297   DeleteRegKey HKCR ${EXT}\shell\PlayWithVLC
298   DeleteRegKey HKCR ${EXT}\shell\AddToPlaylistVLC
299 !macroend
300
301 !macro DeleteContextMenu EXT
302   Push $R0
303   ReadRegStr $R0 HKCR ${EXT} ""
304   !insertmacro DeleteContextMenuExt $R0
305   Pop $R0
306 !macroend
307
308 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
309 ; 3. Delete prefs and cache ;
310 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
311
312 !macro delprefs
313   StrCpy $0 0
314   !define Index 'Line${__LINE__}'
315   "${Index}-Loop:"
316   ; FIXME
317   ; this will loop through all the logged users and "virtual" windows users
318   ; (it looks like users are only present in HKEY_USERS when they are logged in)
319     ClearErrors
320     EnumRegKey $1 HKU "" $0
321     StrCmp $1 "" "${Index}-End"
322     IntOp $0 $0 + 1
323     ReadRegStr $2 HKU "$1\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" AppData
324     StrCmp $2 "" "${Index}-Loop"
325     RMDir /r "$2\vlc"
326     Goto "${Index}-Loop"
327   "${Index}-End:"
328   !undef Index
329 !macroend
330
331 ;;;;;;;;;;;;;;;
332 ; 4. Logging  ;
333 ;;;;;;;;;;;;;;;
334 Var UninstallLog
335 !macro OpenUninstallLog
336   FileOpen $UninstallLog "$INSTDIR\uninstall.log" a
337   FileSeek $UninstallLog 0 END
338 !macroend
339
340 !macro CloseUninstallLog
341   FileClose $UninstallLog
342   SetFileAttributes "$INSTDIR\uninstall.log" HIDDEN
343 !macroend
344
345 ;;;;;;;;;;;;;;;;;;;;
346 ; 5. Installations ;
347 ;;;;;;;;;;;;;;;;;;;;
348 !macro InstallFile FILEREGEX
349   File "${FILEREGEX}"
350   !define Index 'Line${__LINE__}'
351   FindFirst $0 $1 "$INSTDIR\${FILEREGEX}"
352   StrCmp $0 "" "${Index}-End"
353   "${Index}-Loop:"
354     StrCmp $1 "" "${Index}-End"
355     FileWrite $UninstallLog "$1$\r$\n"
356     FindNext $0 $1
357     Goto "${Index}-Loop"
358   "${Index}-End:"
359   !undef Index
360 !macroend
361
362 !macro InstallFolder FOLDER
363   File /r "${FOLDER}"
364   Push "${FOLDER}"
365   Call InstallFolderInternal
366 !macroend
367
368 Function InstallFolderInternal
369   Pop $9
370   !define Index 'Line${__LINE__}'
371   FindFirst $0 $1 "$INSTDIR\$9\*"
372   StrCmp $0 "" "${Index}-End"
373   "${Index}-Loop:"
374     StrCmp $1 "" "${Index}-End"
375     StrCmp $1 "." "${Index}-Next"
376     StrCmp $1 ".." "${Index}-Next"
377     IfFileExists "$9\$1\*" 0 "${Index}-Write"
378       Push $0
379       Push $9
380       Push "$9\$1"
381       Call InstallFolderInternal
382       Pop $9
383       Pop $0
384       Goto "${Index}-Next"
385     "${Index}-Write:"
386     FileWrite $UninstallLog "$9\$1$\r$\n"
387     "${Index}-Next:"
388     FindNext $0 $1
389     Goto "${Index}-Loop"
390   "${Index}-End:"
391   !undef Index
392 FunctionEnd
393 ;;; End of Macros
394
395
396 ;;;;;;;;;;;;;;;;;;;;;;
397 ; Installer sections ;
398 ; The CORE of the    ;
399 ; installer          ;
400 ;;;;;;;;;;;;;;;;;;;;;;
401
402 Section $Name_Section01 SEC01
403   SectionIn 1 2 3 RO
404   SetShellVarContext all
405   SetOutPath "$INSTDIR"
406
407   !insertmacro OpenUninstallLog
408
409   ; VLC.exe, libvlc.dll
410   !insertmacro InstallFile vlc.exe
411   !insertmacro InstallFile vlc.exe.manifest
412
413   ; All dlls
414   !insertmacro InstallFile *.dll
415
416   ; Text files
417   !insertmacro InstallFile *.txt
418
419   ; Subfolders
420   !insertmacro InstallFolder plugins
421   !insertmacro InstallFolder locale
422 @BUILD_OSDMENU_TRUE@ !insertmacro InstallFolder osdmenu
423 @BUILD_SKINS_TRUE@   !insertmacro InstallFolder skins
424 @BUILD_HTTPD_TRUE@   !insertmacro InstallFolder http
425 @BUILD_LUA_TRUE@     !insertmacro InstallFolder lua
426
427
428   ; URLs
429   WriteIniStr "$INSTDIR\${PRODUCT_GROUP} Website.url" "InternetShortcut" "URL" \
430     "${PRODUCT_WEB_SITE}"
431   FileWrite $UninstallLog "${PRODUCT_GROUP} Website.url$\r$\n"
432   WriteIniStr "$INSTDIR\Documentation.url" "InternetShortcut" "URL" \
433     "${PRODUCT_WEB_SITE}/doc/"
434   FileWrite $UninstallLog "Documentation.url$\r$\n"
435   WriteIniStr "$INSTDIR\New_Skins.url" "InternetShortcut" "URL" \
436     "${PRODUCT_WEB_SITE}/vlc/skins.php"
437   FileWrite $UninstallLog "New_Skins.url$\r$\n"
438
439   !insertmacro CloseUninstallLog
440
441   ; Add VLC to "recomended programs" for the following extensions
442   WriteRegStr HKCR Applications\vlc.exe "" ""
443   WriteRegStr HKCR Applications\vlc.exe "FriendlyAppName" "VLC media player"
444   WriteRegStr HKCR Applications\vlc.exe\shell\Open "" $ContextMenuEntry_PlayWith
445   WriteRegStr HKCR Applications\vlc.exe\shell\Open\command "" \
446     '"$INSTDIR\vlc.exe" --started-from-file "%1"'
447   !insertmacro MacroAllExtensions WriteRegStrSupportedTypes
448
449 ; Vista Registration
450   ; Vista detection
451   ReadRegStr $R0 HKLM "SOFTWARE\Microsoft\Windows NT\CurrentVersion" CurrentVersion
452   StrCpy $R1 $R0 3
453   StrCmp $R1 '6.0' lbl_vista lbl_done
454
455   lbl_vista:
456   WriteRegStr HKLM "Software\RegisteredApplications" "VLC" "Software\Clients\Media\VLC\Capabilities"
457   WriteRegStr HKLM "Software\Clients\Media\VLC\Capabilities" "ApplicationName" "VLC media player"
458   WriteRegStr HKLM "Software\Clients\Media\VLC\Capabilities" "ApplicationDescription" "VLC - The video swiss knife"
459
460   lbl_done:
461 SectionEnd
462
463 Section $Name_Section02a SEC02a
464   SectionIn 1 2 3
465   CreateDirectory "$SMPROGRAMS\VideoLAN"
466   CreateDirectory "$SMPROGRAMS\VideoLAN\Quick Settings"
467   CreateDirectory "$SMPROGRAMS\VideoLAN\Quick Settings\Audio"
468   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Audio\Set Audio mode to DirectX (default).lnk" \
469     "$INSTDIR\vlc.exe" "--aout aout_directx --save-config vlc://quit"
470   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Audio\Set Audio mode to Waveout.lnk" \
471     "$INSTDIR\vlc.exe" "--aout waveout --save-config vlc://quit"
472   CreateDirectory "$SMPROGRAMS\VideoLAN\Quick Settings\Interface"
473 @BUILD_SKINS_TRUE@  CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Interface\Set Main Interface to Skinnable.lnk" \
474 @BUILD_SKINS_TRUE@    "$INSTDIR\vlc.exe" "-I skins --save-config vlc://quit"
475   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Interface\Set Main Interface to Qt (default).lnk" \
476     "$INSTDIR\vlc.exe" "-I qt --save-config vlc://quit"
477   CreateDirectory "$SMPROGRAMS\VideoLAN\Quick Settings\Video"
478   ; FIXME add detection for Vista. Direct3D will be default there, for all others it's DirectX
479   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Video\Set Video mode to Direct3D.lnk" \
480     "$INSTDIR\vlc.exe" "--vout direct3d --overlay --directx-hw-yuv --save-config vlc://quit"
481   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Video\Set Video mode to Direct3D (no hardware acceleration).lnk" \
482     "$INSTDIR\vlc.exe" "--vout direct3d --overlay --no-directx-hw-yuv --save-config vlc://quit"
483   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Video\Set Video mode to DirectX.lnk" \
484     "$INSTDIR\vlc.exe" "--vout directx --overlay --directx-hw-yuv --save-config vlc://quit"
485   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Video\Set Video mode to DirectX (no hardware acceleration).lnk" \
486     "$INSTDIR\vlc.exe" "--vout directx --no-overlay --no-directx-hw-yuv --save-config vlc://quit"
487   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Video\Set Video mode to DirectX (no video overlay).lnk" \
488     "$INSTDIR\vlc.exe" "--vout directx --no-overlay --directx-hw-yuv --save-config vlc://quit"
489   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Video\Set Video mode to OpenGL.lnk" \
490     "$INSTDIR\vlc.exe" "--vout opengl --overlay --save-config vlc://quit"
491   CreateShortCut "$SMPROGRAMS\VideoLAN\Quick Settings\Reset VLC media player preferences and cache files.lnk" \
492     "$INSTDIR\vlc.exe" "--reset-config --reset-plugins-cache vlc://quit"
493   CreateShortCut "$SMPROGRAMS\VideoLAN\Documentation.lnk" \
494     "$INSTDIR\Documentation.url"
495   CreateShortCut "$SMPROGRAMS\VideoLAN\Release Notes.lnk" \
496     "$INSTDIR\NEWS.txt" ""
497   CreateShortCut "$SMPROGRAMS\VideoLAN\${PRODUCT_GROUP} Website.lnk" \
498     "$INSTDIR\${PRODUCT_GROUP} Website.url"
499   CreateShortCut "$SMPROGRAMS\VideoLAN\VLC media player.lnk" \
500     "$INSTDIR\vlc.exe" ""
501 SectionEnd
502
503 Section $Name_Section02b SEC02b
504   SectionIn 1 2 3
505   CreateShortCut "$DESKTOP\VLC media player.lnk" \
506     "$INSTDIR\vlc.exe" ""
507 SectionEnd
508
509 !ifdef INSTALL_MOZILLA
510 Section /o $Name_Section03 SEC03
511   SectionIn 3
512
513   SetOutPath "$INSTDIR"
514   !insertmacro OpenUninstallLog
515   !insertmacro InstallFile mozilla\npvlc.dll
516   !insertmacro InstallFile mozilla\npvlc.dll.manifest
517   !insertmacro CloseUninstallLog
518
519   !define Moz "SOFTWARE\MozillaPlugins\@videolan.org/vlc,version=${VERSION}"
520   WriteRegStr HKLM ${Moz} "Description" "VLC Multimedia Plugin"
521   WriteRegStr HKLM ${Moz} "Path" "$INSTDIR\npvlc.dll"
522   WriteRegStr HKLM ${Moz} "Product" "VLC media player"
523   WriteRegStr HKLM ${Moz} "Vendor" "VideoLAN"
524   WriteRegStr HKLM ${Moz} "Version" "${VERSION}"
525
526  ; for very old version of mozilla, these lines may be needed
527  ;Push $R0
528  ;Push $R1
529  ;Push $R2
530
531  ;!define Index 'Line${__LINE__}'
532  ;StrCpy $R1 "0"
533
534  ;"${Index}-Loop:"
535
536  ;  ; Check for Key
537  ;  EnumRegKey $R0 HKLM "SOFTWARE\Mozilla" "$R1"
538  ;  StrCmp $R0 "" "${Index}-End"
539  ;  IntOp $R1 $R1 + 1
540  ;  ReadRegStr $R2 HKLM "SOFTWARE\Mozilla\$R0\Extensions" "Plugins"
541  ;  StrCmp $R2 "" "${Index}-Loop" ""
542
543  ;  CopyFiles "$INSTDIR\npvlc.dll" "$R2"
544  ;  !ifdef LIBVLC_DLL
545  ;  CopyFiles ${LIBVLC_DLL} "$R2"
546  ;  !endif
547  ;  !ifdef LIBVLC_CONTROL_DLL
548  ;  CopyFiles ${LIBVLC_CONTROL_DLL} "$R2"
549  ;  !endif
550  ;  Goto "${Index}-Loop"
551
552  ;"${Index}-End:"
553  ;!undef Index
554
555 SectionEnd
556 !endif
557
558 !ifdef INSTALL_ACTIVEX
559 Section $Name_Section04 SEC04
560   SectionIn 3
561   SetOutPath "$INSTDIR"
562   !insertmacro OpenUninstallLog
563   !insertmacro InstallFile activex\axvlc.dll
564   !insertmacro InstallFile activex\axvlc.dll.manifest
565   !insertmacro CloseUninstallLog
566   RegDLL "$INSTDIR\axvlc.dll"
567 SectionEnd
568 !endif
569
570
571 Section $Name_Section05 SEC05
572   SectionIn 1 2 3
573   WriteRegStr HKCR "AudioCD\shell\PlayWithVLC" "" $ContextMenuEntry_PlayWith
574   WriteRegStr HKCR "AudioCD\shell\PlayWithVLC\command" "" \
575     '"$INSTDIR\vlc.exe" --started-from-file cdda://%1'
576   WriteRegStr HKCR "DVD\shell\PlayWithVLC" "" $ContextMenuEntry_PlayWith
577   WriteRegStr HKCR "DVD\shell\PlayWithVLC\command" "" \
578     '"$INSTDIR\vlc.exe" --started-from-file dvd://%1'
579
580   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayDVDMovieOnArrival" "VLCPlayDVDMovieOnArrival" ""
581   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "Action" $Action_OnArrivalDVD
582   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "DefaultIcon" '"$INSTDIR\vlc.exe",0'
583   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "InvokeProgID" "VLC.DVDMovie"
584   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "InvokeVerb" "play"
585   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival" "Provider" "VideoLAN VLC media player"
586
587   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayCDAudioOnArrival" "VLCPlayCDAudioOnArrival" ""
588   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "Action" $Action_OnArrivalAudioCD
589   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "DefaultIcon" '"$INSTDIR\vlc.exe",0'
590   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "InvokeProgID" "VLC.CDAudio"
591   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "InvokeVerb" "play"
592   WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival" "Provider" "VideoLAN VLC media player"
593   WriteRegStr HKCR "VLC.DVDMovie" "" "VLC DVD Movie"
594   WriteRegStr HKCR "VLC.DVDMovie\shell" "" "Open"
595   WriteRegStr HKCR "VLC.DVDMovie\shell\Open\command" "" \
596     '"$INSTDIR\vlc.exe" --started-from-file dvd://%1'
597   WriteRegStr HKCR "VLC.DVDMovie\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
598   WriteRegStr HKCR "VLC.CDAudio" "" "VLC CD Audio"
599   WriteRegStr HKCR "VLC.CDAudio\shell" "" "Open"
600   WriteRegStr HKCR "VLC.CDAudio\shell\Open\command" "" \
601     '"$INSTDIR\vlc.exe" --started-from-file cdda://%1'
602   WriteRegStr HKCR "VLC.CDAudio\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
603
604 SectionEnd
605
606
607 SectionGroup /e !$Name_Section06 SEC06
608   SectionGroup $Name_SectionGroupAudio
609     !insertmacro MacroAudioExtensions RegisterExtensionSection
610   SectionGroupEnd
611   SectionGroup $Name_SectionGroupVideo
612     !insertmacro MacroVideoExtensions RegisterExtensionSection
613   SectionGroupEnd
614   SectionGroup $Name_SectionGroupOther
615     !insertmacro MacroOtherExtensions RegisterExtensionSection
616   SectionGroupEnd
617 SectionGroupEnd
618
619 Section $Name_Section07 SEC07
620   SectionIn 1 3
621   !insertmacro MacroAllExtensions AddContextMenu
622   !insertmacro AddContextMenuExt "Directory"
623 SectionEnd
624
625 Section $Name_Section08 SEC08
626   !insertmacro delprefs
627 SectionEnd
628
629 ; Installer section descriptions
630 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
631   !insertmacro MUI_DESCRIPTION_TEXT ${SEC01} $Desc_Section01
632   !insertmacro MUI_DESCRIPTION_TEXT ${SEC02a} $Desc_Section02a
633   !insertmacro MUI_DESCRIPTION_TEXT ${SEC02b} $Desc_Section02b
634 @BUILD_MOZILLA_TRUE@ !insertmacro MUI_DESCRIPTION_TEXT ${SEC03} $Desc_Section03
635 @BUILD_ACTIVEX_TRUE@ !insertmacro MUI_DESCRIPTION_TEXT ${SEC04} $Desc_Section04
636   !insertmacro MUI_DESCRIPTION_TEXT ${SEC05} $Desc_Section05
637   !insertmacro MUI_DESCRIPTION_TEXT ${SEC06} $Desc_Section06
638   !insertmacro MUI_DESCRIPTION_TEXT ${SEC07} $Desc_Section07
639   !insertmacro MUI_DESCRIPTION_TEXT ${SEC08} $Desc_Section08
640 !insertmacro MUI_FUNCTION_DESCRIPTION_END
641
642 ;;; Start function
643 Function .onInit
644   !insertmacro MUI_LANGDLL_DISPLAY
645
646   !include "languages\english.nsh"
647   StrCmp $LANGUAGE ${LANG_FRENCH} French 0
648   StrCmp $LANGUAGE ${LANG_ITALIAN} Italian 0
649   StrCmp $LANGUAGE ${LANG_HUNGARIAN} Hungarian 0
650   StrCmp $LANGUAGE ${LANG_ROMANIAN} Romanian 0
651   StrCmp $LANGUAGE ${LANG_CATALAN} Catalan 0
652   StrCmp $LANGUAGE ${LANG_BULGARIAN} Bulgarian 0
653   StrCmp $LANGUAGE ${LANG_SLOVAK} Slovak 0
654   StrCmp $LANGUAGE ${LANG_POLISH} Polish 0
655   StrCmp $LANGUAGE ${LANG_DUTCH} Dutch 0
656   StrCmp $LANGUAGE ${LANG_SIMPCHINESE} SChinese 0
657   StrCmp $LANGUAGE ${LANG_FINNISH} Finnish 0
658   StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} Brazilian EndLanguageCmp
659   French:
660   !include "languages\french.nsh"
661   Goto EndLanguageCmp
662   Italian:
663   !include "languages\italian.nsh"
664   Goto EndLanguageCmp
665   Hungarian:
666   !include "languages\hungarian.nsh"
667   Goto EndLanguageCmp
668   Romanian:
669   !include "languages\romanian.nsh"
670   Goto EndLanguageCmp
671   Catalan:
672   !include "languages\catalan.nsh"
673   Goto EndLanguageCmp
674   Bulgarian:
675   !include "languages\bulgarian.nsh"
676   Goto EndLanguageCmp
677   Slovak:
678   !include "languages\slovak.nsh"
679   Goto EndLanguageCmp
680   Polish:
681   !include "languages\polish.nsh"
682   Goto EndLanguageCmp
683   Dutch:
684   !include "languages\dutch.nsh"
685   Goto EndLanguageCmp
686   Schinese:
687   !include "languages\schinese.nsh"
688   Goto EndLanguageCmp
689   Finnish:
690   !include "languages\finnish.nsh"
691   Goto EndLanguageCmp
692   Brazilian:
693   !include "languages\brazilian_portuguese.nsh"
694   EndLanguageCmp:
695
696   ReadRegStr $R0  ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
697   "UninstallString"
698   StrCmp $R0 "" done
699
700   MessageBox MB_YESNO|MB_ICONEXCLAMATION $Message_AlreadyInstalled IDNO done
701
702   ;Run the uninstaller
703   ;uninst:
704     ClearErrors
705     ExecWait '$R0 _?=$INSTDIR' ;Do not copy the uninstaller to a temp file
706   done:
707
708 FunctionEnd
709
710 ;; End function
711 Section -Post
712   WriteUninstaller "$INSTDIR\uninstall.exe"
713   WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "InstallDir" $INSTDIR
714   WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "Version" "${VERSION}"
715   WriteRegStr HKLM "${PRODUCT_DIR_REGKEY}" "" "$INSTDIR\vlc.exe"
716
717   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
718     "DisplayName" "$(^Name)"
719   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
720     "UninstallString" "$INSTDIR\uninstall.exe"
721   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
722     "InstallLocation" "$INSTDIR"
723   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
724     "DisplayIcon" "$INSTDIR\vlc.exe"
725   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
726     "DisplayVersion" "${PRODUCT_VERSION}"
727   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
728     "URLInfoAbout" "${PRODUCT_WEB_SITE}"
729   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
730     "Publisher" "${PRODUCT_PUBLISHER}"
731   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
732     "VersionMajor"  "@VERSION_MAJOR@"
733   WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" \
734     "VersionMinor" "@VERSION_MINOR@"
735 SectionEnd
736
737 ;;;;;;;;;;;;;;;;;;;;;;;;
738 ; Uninstaller sections ;
739 ;;;;;;;;;;;;;;;;;;;;;;;;
740
741 ; TrimNewlines (copied from NSIS documentation)
742 ; input, top of stack  (e.g. whatever$\r$\n)
743 ; output, top of stack (replaces, with e.g. whatever)
744 ; modifies no other variables.
745
746 Function un.TrimNewlines
747  Exch $R0
748  Push $R1
749  Push $R2
750  StrCpy $R1 0
751
752  loop:
753    IntOp $R1 $R1 - 1
754    StrCpy $R2 $R0 1 $R1
755    StrCmp $R2 "$\r" loop
756    StrCmp $R2 "$\n" loop
757    IntOp $R1 $R1 + 1
758    IntCmp $R1 0 no_trim_needed
759    StrCpy $R0 $R0 $R1
760
761  no_trim_needed:
762    Pop $R2
763    Pop $R1
764    Exch $R0
765 FunctionEnd
766
767 Function un.RemoveEmptyDirs
768   Pop $9
769   !define Index 'Line${__LINE__}'
770   FindFirst $0 $1 "$INSTDIR$9*"
771   StrCmp $0 "" "${Index}-End"
772   "${Index}-Loop:"
773     StrCmp $1 "" "${Index}-End"
774     StrCmp $1 "." "${Index}-Next"
775     StrCmp $1 ".." "${Index}-Next"
776       Push $0
777       Push $1
778       Push $9
779       Push "$9$1\"
780       Call un.RemoveEmptyDirs
781       Pop $9
782       Pop $1
783       Pop $0
784     "${Index}-Remove:"
785     RMDir "$INSTDIR$9$1"
786     "${Index}-Next:"
787     FindNext $0 $1
788     Goto "${Index}-Loop"
789   "${Index}-End:"
790   FindClose $0
791   !undef Index
792 FunctionEnd
793
794 Section "un.$Name_Section91" SEC91
795   SectionIn 1 2 3 RO
796   SetShellVarContext all
797
798   !insertmacro MacroAllExtensions DeleteContextMenu
799   !insertmacro MacroAllExtensions UnRegisterExtensionSection
800   !insertmacro DeleteContextMenuExt "Directory"
801
802   ;remove activex plugin
803   UnRegDLL "$INSTDIR\axvlc.dll"
804   Delete /REBOOTOK "$INSTDIR\axvlc.dll"
805   Delete /REBOOTOK "$INSTDIR\axvlc.dll.manifest"
806
807   ;remove mozilla plugin
808   Push $R0
809   Push $R1
810   Push $R2
811
812   !define Index 'Line${__LINE__}'
813   StrCpy $R1 "0"
814
815   "${Index}-Loop:"
816
817     ; Check for Key
818     EnumRegKey $R0 HKLM "SOFTWARE\Mozilla" "$R1"
819     StrCmp $R0 "" "${Index}-End"
820     IntOp $R1 $R1 + 1
821     ReadRegStr $R2 HKLM "SOFTWARE\Mozilla\$R0\Extensions" "Plugins"
822     StrCmp $R2 "" "${Index}-Loop" ""
823
824     ; old files (0.8.5 and before) that may be lying around
825     Delete /REBOOTOK "$R2\npvlc.dll"
826     Delete /REBOOTOK "$R2\libvlc.dll"
827     Delete /REBOOTOK "$R2\vlcintf.xpt"
828     Goto "${Index}-Loop"
829
830   "${Index}-End:"
831   !undef Index
832   Delete /REBOOTOK "$INSTDIR\npvlc.dll"
833   Delete /REBOOTOK "$INSTDIR\npvlc.dll.manifest"
834
835   RMDir "$SMPROGRAMS\VideoLAN"
836   RMDir /r $SMPROGRAMS\VideoLAN
837
838   FileOpen $UninstallLog "$INSTDIR\uninstall.log" r
839   UninstallLoop:
840     ClearErrors
841     FileRead $UninstallLog $R0
842     IfErrors UninstallEnd
843     Push $R0
844     Call un.TrimNewLines
845     Pop $R0
846     Delete "$INSTDIR\$R0"
847     Goto UninstallLoop
848   UninstallEnd:
849   FileClose $UninstallLog
850   Delete "$INSTDIR\uninstall.log"
851   Delete "$INSTDIR\uninstall.exe"
852   Push "\"
853   Call un.RemoveEmptyDirs
854   RMDir "$INSTDIR"
855
856   DeleteRegKey HKLM Software\VideoLAN
857
858   DeleteRegKey HKCR Applications\vlc.exe
859   DeleteRegKey HKCR AudioCD\shell\PlayWithVLC
860   DeleteRegKey HKCR DVD\shell\PlayWithVLC
861   DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayDVDMovieOnArrival" "VLCPlayDVDMovieOnArrival"
862   DeleteRegKey HKLM Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayDVDMovieOnArrival
863   DeleteRegValue HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayCDAudioOnArrival" "VLCPlayCDAudioOnArrival"
864   DeleteRegKey HKLM Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayCDAudioOnArrival
865   DeleteRegKey HKLM Software\Clients\Media\VLC
866   DeleteRegKey HKCR "VLC.MediaFile"
867
868   DeleteRegKey HKLM \
869     "SOFTWARE\MozillaPlugins\@videolan.org/vlc,version=${VERSION}"
870
871   DeleteRegKey HKLM \
872     "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_NAME}"
873
874   Delete "$DESKTOP\VLC media player.lnk"
875
876   DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
877   DeleteRegKey HKLM "${PRODUCT_DIR_REGKEY}"
878   SetAutoClose true
879 SectionEnd
880
881 Section /o "un.$Name_Section92" SEC92
882   !insertmacro delprefs
883 SectionEnd
884
885 ; Uninstaller section descriptions
886 !insertmacro MUI_UNFUNCTION_DESCRIPTION_BEGIN
887   !insertmacro MUI_DESCRIPTION_TEXT ${SEC91} $Desc_Section91
888   !insertmacro MUI_DESCRIPTION_TEXT ${SEC92} $Desc_Section92
889 !insertmacro MUI_UNFUNCTION_DESCRIPTION_END
890
891 ;Function un.onUninstSuccess
892 ;  HideWindow
893 ;  MessageBox MB_ICONINFORMATION|MB_OK \
894 ;    "$(^Name) was successfully removed from your computer."
895 ;FunctionEnd
896
897 Function un.onInit
898   !insertmacro MUI_UNGETLANGUAGE
899
900   !include "languages\english.nsh"
901   StrCmp $LANGUAGE ${LANG_FRENCH} French 0
902   StrCmp $LANGUAGE ${LANG_ITALIAN} Italian 0
903   StrCmp $LANGUAGE ${LANG_HUNGARIAN} Hungarian 0
904   StrCmp $LANGUAGE ${LANG_ROMANIAN} Romanian 0
905   StrCmp $LANGUAGE ${LANG_CATALAN} Catalan 0
906   StrCmp $LANGUAGE ${LANG_BULGARIAN} Bulgarian 0
907   StrCmp $LANGUAGE ${LANG_SLOVAK} Slovak 0
908   StrCmp $LANGUAGE ${LANG_POLISH} Polish 0
909   StrCmp $LANGUAGE ${LANG_DUTCH} Dutch 0
910   StrCmp $LANGUAGE ${LANG_SIMPCHINESE} SChinese 0
911   StrCmp $LANGUAGE ${LANG_FINNISH} Finnish 0
912   StrCmp $LANGUAGE ${LANG_PORTUGUESEBR} Brazilian EndLanguageCmp
913   French:
914   !include "languages\french.nsh"
915   Goto EndLanguageCmp
916   Italian:
917   !include "languages\italian.nsh"
918   Goto EndLanguageCmp
919   Hungarian:
920   !include "languages\hungarian.nsh"
921   Goto EndLanguageCmp
922   Romanian:
923   !include "languages\romanian.nsh"
924   Goto EndLanguageCmp
925   Catalan:
926   !include "languages\catalan.nsh"
927   Goto EndLanguageCmp
928   Bulgarian:
929   !include "languages\bulgarian.nsh"
930   Goto EndLanguageCmp
931   Slovak:
932   !include "languages\slovak.nsh"
933   Goto EndLanguageCmp
934   Polish:
935   !include "languages\polish.nsh"
936   Goto EndLanguageCmp
937   Dutch:
938   !include "languages\dutch.nsh"
939   Goto EndLanguageCmp
940   Schinese:
941   !include "languages\schinese.nsh"
942   Goto EndLanguageCmp
943   Finnish:
944   !include "languages\finnish.nsh"
945   Goto EndLanguageCmp
946   Brazilian:
947   !include "languages\brazilian_portuguese.nsh"
948   EndLanguageCmp:
949
950 FunctionEnd