splash.txt 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. Splash.dll - small (4k), simple plugin that lets you throw
  2. up a splash screen in NSIS installers.
  3. --- UPDATED in 2.0b0 - will break old scripts ---
  4. To use:
  5. Create a .BMP file of your splash screen.
  6. (optional) Create a .WAV file to play while your splash screen shows.
  7. Add the following lines to your .NSI file:
  8. Function .onInit
  9. SetOutPath $TEMP
  10. File /oname=spltmp.bmp "my_splash.bmp"
  11. ; optional
  12. ; File /oname=spltmp.wav "my_splashsound.wav"
  13. splash::show 1000 $TEMP\spltmp
  14. Pop $0 ; $0 has '1' if the user closed the splash screen early,
  15. ; '0' if everything closed normally, and '-1' if some error occurred.
  16. Delete $TEMP\spltmp.bmp
  17. ; Delete $TEMP\spltmp.wav
  18. FunctionEnd
  19. Note that the first parameter to splash.exe is the length to show the
  20. screen for (in milliseconds), and the second is the splash bitmap filename (without
  21. the .bmp). The BMP file used will be this parameter.bmp, and the wave file used
  22. (if present) will be this parameter.wav.
  23. (If you already have an .onInit function, put that in it)
  24. Note: the return value of splash is 1 if the user closed the splash
  25. screen early (pop it from the stack)
  26. -Justin
  27. Converted to a plugin DLL by Amir Szekely (kichik)