使用SkinSharp皮肤实例

;--------------------------------
;Include Modern UI
 !include "MUI2.nsh"
;--------------------------------
;General
 ;Name and file
 Name "加载皮肤演示"
 OutFile "Skin2.exe"
 ;Default installation folder
 InstallDir "$LOCALAPPDATAyhxs3344"
 ;Get installation folder from registry if available
 InstallDirRegKey HKCU "Softwareyhxs3344Soft" ""
 ;Request application privileges for Windows Vista
 RequestExecutionLevel user
;--------------------------------
;Interface Settings
 !define MUI_ABORTWARNING
;--------------------------------
;Pages
 !insertmacro MUI_PAGE_WELCOME
 !insertmacro MUI_PAGE_LICENSE "${NSISDIR}DocsModern UILicense.txt"
 !insertmacro MUI_PAGE_COMPONENTS
 !insertmacro MUI_PAGE_DIRECTORY
 !insertmacro MUI_PAGE_INSTFILES
 !insertmacro MUI_PAGE_FINISH
 !insertmacro MUI_UNPAGE_WELCOME
 !insertmacro MUI_UNPAGE_CONFIRM
 !insertmacro MUI_UNPAGE_INSTFILES
 !insertmacro MUI_UNPAGE_FINISH
;--------------------------------
;Languages
 !insertmacro MUI_LANGUAGE "SimpChinese"
Function .onInit
 InitPluginsDir
 SetOutPath $PLUGINSDIR
 File SkinH.dll
 File china.she
 System::Call SkinH::SkinH_AttachEx(t'$PLUGINSDIRchina.she',t'mhgd')
;增加aero效果
 System::Call SkinH::SkinH_SetAero(i1)
################ SkinSharp补丁, 让小衣服不显示 ################
 System::Call Kernel32::GetModuleHandle(t"SkinH.dll")i.r0
 IntOp $0 $0 + 0x0002CA98
 System::Call Kernel32::GetCurrentProcess()i.s
 System::Call Kernel32::VirtualProtectEx(is,ir0,i4,i0x40,*i)
 System::Call "*$0(&i1 0)"
###############################################################
FunctionEnd
;--------------------------------
;Installer Sections
Section "yhxs3344" yhxs3344
; SetOutPath "$INSTDIR"
 ;ADD YOUR OWN FILES HERE...
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
SectionEnd
;--------------------------------
;Descriptions
 ;Language strings
 LangString DESC_D8 ${LANG_ENGLISH} "yhxs3344.Net."
 ;Assign language strings to sections
 !insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
 !insertmacro MUI_DESCRIPTION_TEXT ${yhxs3344} $(DESC_D8)
 !insertmacro MUI_FUNCTION_DESCRIPTION_END
;--------------------------------
;Uninstaller Section
Section "Uninstall"
 ;ADD YOUR OWN FILES HERE...
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
 Sleep 1000
SectionEnd
Function .onGUIEnd
; 让插件目录可顺利删除
 System::Call Kernel32::GetModuleHandle(t"SkinH.dll")i.s
 System::Call Kernel32::FreeLibrary(is)
 System::Call Kernel32::SetCurrentDirectory(t"$EXEDIR")
FunctionEnd
© 版权声明
THE END
喜欢就支持一下吧
点赞14 分享
评论 抢沙发

请登录后发表评论

    暂无评论内容