最新消息:

暴风影音去广告补丁源代码

nsis 永恒心锁 1848浏览 0评论
;暴风影音去广告补丁
 ;编写:寒星
 !define PRODUCT_NAME "暴风影音去广告补丁"
 !define PRODUCT_VERSION "v1.6版"
 !define PRODUCT_PUBLISHER "寒星工作室"
 !define PRODUCT_WEB_SITE "http://www.hxlive.cn"
 SetCompressor /solid lzma
 SetCompressorDictSize 32
 ;----------------基础信息--------------------------------------
 Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
 SetDatablockOptimize on
 outfile "Storm3 NoAD v1.6.exe"
 Caption "暴风影音3去广告补丁 v1.6"
 BrandingText " 寒星工作室 ${__DATE__} "
 ;---------------------安装代码使用-------------------------------
 !include "MUI.nsh"
 !include "UsefulLib.nsh"
 !define MUI_ICON "Storm.ico"
 Page custom Storm2
 Page custom do
 !insertmacro MUI_LANGUAGE "SimpChinese"
 ChangeUI all default.exe
 MiscButtonText "" "执行" "" "完成"
 ;---------------------版本信息--------------------------------
 VIProductVersion "1.6.0.0314"
 VIAddVersionKey /LANG=${LANG_SimpChinese} "FileVersion" "1.6.0.0314"
 VIAddVersionKey /LANG=${LANG_SimpChinese} "ProductName" "${PRODUCT_NAME} ${PRODUCT_VERSION}"
 VIAddVersionKey /LANG=${LANG_SimpChinese} "Comments" "${PRODUCT_NAME}"
 VIAddVersionKey /LANG=${LANG_SimpChinese} "CompanyName" "寒星工作室"
 VIAddVersionKey /LANG=${LANG_SimpChinese} "LegalCopyright" "版权所有 (C) 寒星工作室"
 VIAddVersionKey /LANG=${LANG_SimpChinese} "FileDescription" "${PRODUCT_NAME} ${PRODUCT_VERSION}"
 ;---------------------------------------------------------
 Section
 SectionEnd
 ReserveFile "${NSISDIR}PluginsInstallOptions.dll"
 ReserveFile "Storm216.ini"
 ReserveFile "TOP.bmp"
 Function Storm2
 !addplugindir E:安装制作NSISPlugins
 FindProcDLL::FindProc "Storm.exe"
 StrCmp $R0 1 +3 +1
 FindProcDLL::FindProc "Storm2.exe"
 StrCmp $R0 1 +1 +4
 MessageBox MB_ICONINFORMATION|MB_RETRYCANCEL "安装程序检测到 暴风影音 正在运行!请退出程序重试或取消本次安装!" IDRetry retry IDCANCEL Cancel
 Retry:
 Goto -5
 Cancel:
 Quit
 InitPluginsDir
 File /oname=$PLUGINSDIRStorm216.ini "Storm216.ini"
 File /oname=$PLUGINSDIR op.bmp "top.bmp"
 WriteINIStr "$PLUGINSDIRStorm216.ini" "Field 1" "Text" $PLUGINSDIR op.bmp
 ReadRegStr $R1 HKLM "SOFTWAREMicrosoftWindowsCurrentVersionUninstallstorm2" "DisplayIcon"
 StrCpy $R2 $R1 -9
 WriteINIStr "$PLUGINSDIRStorm216.ini" "Field 5" "State" $R2
 InstallOptions::initDialog /NOUNLOAD "$PLUGINSDIRStorm216.ini"
 Pop $0
 InstallOptions::show
 Pop $0
 FunctionEnd
 Function Do
 ReadINIStr $R3 "$PLUGINSDIRStorm216.ini" "Field 5" "State"
 IfFileExists "$R3Storm.exe" +3 +1
 MessageBox MB_ICONINFORMATION|MB_OK " 我很确定您没有安装暴风影音!点击 确定 后退出!"
 Quit
 SetOutPath "$R3Media"
 IfFileExists "$R3stcon.ini" +1 +3
 File /a stcon.ini
 File /a video_style_list.xml
 SetOutPath "$R3"
 IfFileExists "$R3Media2.dll" +1 +2
 Delete "$R3Media2.dll"
 CreateDirectory "$R3Media2.dll"
 ReadINIStr $R4 "$PLUGINSDIRStorm216.ini" "Field 6" "State"
 StrCmp $R4 1 +1 +15
 !addplugindir E:NSISPlugins
 KillProcDLL::KillProc "stormliv.exe"
 Rename "$R3stormliv.exe" "$R3stormliv.bak"
 CreateDirectory "$R3stormliv.exe"
 SetShellVarContext all
 SetOutPath "$APPDATAStormTemp"
 Rename "update.exe" "update.bak"
 CreateDirectory "$APPDATAStormTempupdate.exe"
 Services::SendServiceCommand 'Stop' 'ccosm'
 Services::SendServiceCommand 'Delete' 'ccosm'
 ReadINIStr $R5 "$PLUGINSDIRStorm216.ini" "Field 7" "State"
 StrCmp $R5 1 +1 +2
 SetOutPath $R3
 File "restore.exe"
 MessageBox MB_ICONINFORMATION|MB_OK "去广告和删服务补丁完毕,点击 确定 后退出!"
 Goto +2
 MessageBox MB_ICONINFORMATION|MB_OK "补丁应用完毕,点击 确定 后退出!"
 FunctionEnd
永恒心锁,版权所有丨如未注明,均为转载丨本网站采用BY-NC-SA协议进行授权

转载请注明:永恒心锁-分享互联网 » 暴风影音去广告补丁源代码

您必须 登录 才能发表评论!