]> git.sesse.net Git - vlc/commitdiff
same thing
authorAntoine Cellerier <dionoea@videolan.org>
Mon, 6 Jun 2005 00:22:59 +0000 (00:22 +0000)
committerAntoine Cellerier <dionoea@videolan.org>
Mon, 6 Jun 2005 00:22:59 +0000 (00:22 +0000)
vlc.win32.nsi

index 37d0b9c83087dee336775dae36fe26f4dfc00df7..4f49061c587c0d3ff11ee719cf7d4d576c53e7a8 100644 (file)
@@ -197,9 +197,38 @@ Section /o "Mozilla plugin" SEC03
   SectionIn 2 3\r
   File /r mozilla\r
 \r
-  WriteRegStr HKLM \\r
-    SOFTWARE\MozillaPlugins\@videolan.org/vlc,version=${VERSION} \\r
-    "Path" '"$INSTDIR\mozilla\npvlc.dll"'\r
+  ; doesn't work. bug in mozilla/mozilla firefox or moz documentation (xpt file isn't loaded)\r
+  ; see mozilla bugs 184506 and 159445\r
+  ;!define Moz "SOFTWARE\MozillaPlugins\@videolan.org/vlc,version=${VERSION}"\r
+  ;WriteRegStr HKLM ${Moz} "Description" "VideoLAN VLC plugin for Mozilla"\r
+  ;WriteRegStr HKLM ${Moz} "Path" "$INSTDIR\mozilla\npvlc.dll"\r
+  ;WriteRegStr HKLM ${Moz} "Product" "VLC media player"\r
+  ;WriteRegStr HKLM ${Moz} "Vendor" "VideoLAN"\r
+  ;WriteRegStr HKLM ${Moz} "Version" "${VERSION}"\r
+  ;WriteRegStr HKLM ${Moz} "XPTPath" "$INSTDIR\mozilla\vlcintf.xpt"\r
+\r
+  Push $R0\r
+  Push $R1\r
+  Push $R2\r
+\r
+  !define Index 'Line${__LINE__}'\r
+  StrCpy $R1 "0"\r
+\r
+  "${Index}-Loop:"\r
+\r
+    ; Check for Key\r
+    EnumRegKey $R0 HKLM "SOFTWARE\Mozilla" "$R1"\r
+    StrCmp $R0 "" "${Index}-End"\r
+    IntOp $R1 $R1 + 1\r
+    ReadRegStr $R2 HKLM "SOFTWARE\Mozilla\$R0\Extensions" "Plugins"\r
+    StrCmp $R2 "" "${Index}-Loop" ""\r
+\r
+    CopyFiles "$INSTDIR\mozilla\*" "$R2"\r
+    Goto "${Index}-Loop"\r
+\r
+  "${Index}-End:"\r
+  !undef Index\r
+\r
 SectionEnd\r
 \r
 Section /o "ActiveX plugin" SEC04\r
@@ -276,7 +305,7 @@ SectionEnd
   !insertmacro MUI_DESCRIPTION_TEXT ${SEC02} \\r
     "Adds icons to your start menu and your desktop for easy access"\r
   !insertmacro MUI_DESCRIPTION_TEXT ${SEC03} \\r
-    "The VLC mozilla plugin"\r
+    "The VLC Mozilla and Mozilla Firefox plugin"\r
   !insertmacro MUI_DESCRIPTION_TEXT ${SEC04} \\r
     "The VLC ActiveX plugin"\r
   !insertmacro MUI_DESCRIPTION_TEXT ${SEC05} \\r
@@ -340,6 +369,30 @@ Section Uninstall
   UnRegDLL "$INSTDIR\axvlc.dll"\r
   Delete /REBOOTOK "$INSTDIR\axvlc.dll"\r
 \r
+  ;remove mozilla plugin\r
+  Push $R0\r
+  Push $R1\r
+  Push $R2\r
+\r
+  !define Index 'Line${__LINE__}'\r
+  StrCpy $R1 "0"\r
+\r
+  "${Index}-Loop:"\r
+\r
+    ; Check for Key\r
+    EnumRegKey $R0 HKLM "SOFTWARE\Mozilla" "$R1"\r
+    StrCmp $R0 "" "${Index}-End"\r
+    IntOp $R1 $R1 + 1\r
+    ReadRegStr $R2 HKLM "SOFTWARE\Mozilla\$R0\Extensions" "Plugins"\r
+    StrCmp $R2 "" "${Index}-Loop" ""\r
+\r
+    Delete "$R2\vlcintf.xpt"\r
+    Delete "$R2\npvlc.dll"\r
+    Goto "${Index}-Loop"\r
+\r
+  "${Index}-End:"\r
+  !undef Index\r
+\r
   RMDir "$SMPROGRAMS\VideoLAN"\r
   RMDir /r $SMPROGRAMS\VideoLAN\r
   RMDir /r $INSTDIR\r