[vlc-commits] nsis: Associate VLC with blu-ray discs

Hugo Beauzée-Luyssen git at videolan.org
Thu Jan 5 15:37:05 CET 2017


vlc | branch: master | Hugo Beauzée-Luyssen <hugo at beauzee.fr> | Thu Jan  5 14:15:30 2017 +0100| [a70e31ea06ef64071cec87251535f465fe1e7e73] | committer: Hugo Beauzée-Luyssen

nsis: Associate VLC with blu-ray discs

Fix #16864

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=a70e31ea06ef64071cec87251535f465fe1e7e73
---

 extras/package/win32/NSIS/languages/declaration.nsh |  1 +
 extras/package/win32/NSIS/languages/english.nsh     |  1 +
 extras/package/win32/NSIS/vlc.win32.nsi.in          | 13 +++++++++++++
 3 files changed, 15 insertions(+)

diff --git a/extras/package/win32/NSIS/languages/declaration.nsh b/extras/package/win32/NSIS/languages/declaration.nsh
index ef5fbc2..42674fd 100644
--- a/extras/package/win32/NSIS/languages/declaration.nsh
+++ b/extras/package/win32/NSIS/languages/declaration.nsh
@@ -44,6 +44,7 @@ Var Action_OnArrivalSVCDMovie
 Var Action_OnArrivalVideoFiles
 Var Action_OnArrivalMusicFiles
 Var Action_OnArrivalDVDAudio
+Var Action_OnArrivalBluray
 
 Var License_NextText
 
diff --git a/extras/package/win32/NSIS/languages/english.nsh b/extras/package/win32/NSIS/languages/english.nsh
index f42b1dd..d0cf32f 100644
--- a/extras/package/win32/NSIS/languages/english.nsh
+++ b/extras/package/win32/NSIS/languages/english.nsh
@@ -56,6 +56,7 @@ StrCpy $Action_OnArrivalSVCDMovie "Play SVCD movie"
 StrCpy $Action_OnArrivalVideoFiles "Play video files"
 StrCpy $Action_OnArrivalMusicFiles "Play audio files"
 StrCpy $Action_OnArrivalDVDAudio "Play audio DVD"
+StrCpy $Action_OnArrivalBluray "Play Blu-ray"
 
 StrCpy $License_NextText "You are now aware of your rights. Click Next to continue."
 
diff --git a/extras/package/win32/NSIS/vlc.win32.nsi.in b/extras/package/win32/NSIS/vlc.win32.nsi.in
index e111f96..6c5d2cb 100644
--- a/extras/package/win32/NSIS/vlc.win32.nsi.in
+++ b/extras/package/win32/NSIS/vlc.win32.nsi.in
@@ -364,6 +364,13 @@ ${MementoSection} $Name_Section05 SEC05
   WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayMusicFilesOnArrival" "InvokeVerb" "Open"
   WriteRegStr HKLM "SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayMusicFilesOnArrival" "Provider" "VideoLAN VLC media player"
 
+  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\EventHandlers\PlayBlurayOnArrival" "VLCPlayBlurayOnArrival" ""
+  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayBlurayOnArrival" "Action" $Action_OnArrivalBluray
+  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayBlurayOnArrival" "DefaultIcon" '"$INSTDIR\vlc.exe",0'
+  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayBlurayOnArrival" "InvokeProgID" "VLC.Bluray"
+  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayBlurayOnArrival" "InvokeVerb" "Open"
+  WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Explorer\AutoplayHandlers\Handlers\VLCPlayBlurayOnArrival" "Provider" "VideoLAN VLC media player"
+
   WriteRegStr HKCR "VLC.DVDMovie" "" "VLC DVD Movie"
   WriteRegStr HKCR "VLC.DVDMovie\shell" "" "Open"
   WriteRegStr HKCR "VLC.DVDMovie\shell\Open\command" "" \
@@ -394,6 +401,12 @@ ${MementoSection} $Name_Section05 SEC05
      '"$INSTDIR\vlc.exe" %1'
   WriteRegStr HKCR "VLC.OPENFolder\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
 
+  WriteRegStr HKCR "VLC.Bluray" "" "VLC Bluray"
+  WriteRegStr HKCR "VLC.Bluray\shell" "" "Open"
+  WriteRegStr HKCR "VLC.Bluray\shell\Open\command" "" \
+    '"$INSTDIR\vlc.exe" --started-from-file bluray:///%1'
+  WriteRegStr HKCR "VLC.Bluray\DefaultIcon" "" '"$INSTDIR\vlc.exe",0'
+
 ${MementoSectionEnd}
 
 



More information about the vlc-commits mailing list