Contrib/ExperienceUI/XPUI-Setup.nsi
author Dan
Sat, 18 Apr 2009 07:32:54 -0400
changeset 3 b081db857e2f
parent 0 d5ce4c64ef88
permissions -rwxr-xr-x
XPUI_BGIMAGE working under UNIX now
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     1
; ExperienceUI for NSIS 1.11
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     2
; Setup Script
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     3
; Copyright © 2004-2006 Dan Fuhry aka dandaman32
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     4
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     5
; This program is free software; you redistribute and/or modify it
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     6
; under the terms of the zlib/libpng license.
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     7
; This program is distributed in the hope that it will be useful,
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     8
; but WITHOUT ANY WARRANTY; without even the implied warranty of
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     9
; merchantability or fitness for a particular purpose.  See the
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    10
; zlib/libpng license for details.
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    11
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    12
; You should have received a copy of the zlib/libpng license with
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    13
; this program; if not, visit http://xpui.sf.net/docs/?start=legal.htm.
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    14
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    15
; This script requires the following add-ons and libraries in order to compile:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    16
; * ExperienceUI for NSIS SDK v1.11 or later - http://xpui.sourceforge.net/
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    17
; * Component Manager 0.2 or later - http://xpui.sourceforge.net/page/compmgr/
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    18
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    19
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    20
; First Things First
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    21
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    22
SetCompressor /FINAL /SOLID lzma
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    23
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    24
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    25
; Declarations
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    26
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    27
Name "ExperienceUI for NSIS"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    28
Caption "ExperienceUI SDK Setup"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    29
OutFile "..\..\ExperienceUI-1.11.exe"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    30
CheckBitmap "${NSISDIR}\Contrib\Graphics\Checks\Modern.bmp"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    31
!define /date XPUI_BUILD_ID "%H%M-%y%m%d"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    32
!define /date XPUI_BUILD_ID_DECIMAL "%y%m%d.%H%M"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    33
!define XPUI_SYSDIR "."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    34
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    35
InstType "Full Install"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    36
InstType "Standard Install"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    37
InstType "Minimal Install"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    38
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    39
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    40
; ExperienceUI Settings
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    41
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    42
!define XPUI_DIRECTORYPAGE_TEXT "Setup will install $(^Name) in the following folder. To install in this folder, leave the text below as-is. To install in a different folder, enter one below, or click Browse. $_CLICK$\n$\nNOTE: You need to have write access to the directory 2 levels up from the install directory,$\ni. e. if you install in C:\Program Files\NSIS\Contrib\ExperienceUI, you need to have write access to C:\Program Files\NSIS."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    43
!define XPUI_ABORTWARNING
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    44
!define XPUI_UNABORTWARNING
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    45
!define XPUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\XPUI-Install.ico"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    46
!define XPUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\XPUI-UnInstall.ico"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    47
!define XPUI_BRANDINGTEXT "ExperienceUI for NSIS ${XPUI_VERSION}"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    48
!define XPUI_SKIN "Windows XP"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    49
!define XPUI_LICENSEPAGE_CHECKBOX
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    50
!define XPUI_DISABLEBG
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    51
!define XPUI_FINISHPAGE_DOCS
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    52
!define XPUI_FINISHPAGE_DOCS_FILE "$INSTDIR\..\..\Docs\ExperienceUI\open_popup.hta"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    53
!define XPUI_VERBOSE 4
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    54
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    55
!define CM_STARTMENU_REG_ROOT HKLM
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    56
!define CM_STARTMENU_REG_KEY  "Software\NSIS\ExperienceUI"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    57
!define CM_STARTMENU_REG_VALUE "StartMenuFolder"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    58
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    59
!include XPUI.nsh
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    60
!include CM.nsh
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    61
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    62
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    63
; Compile-time Options
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    64
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    65
; Define to include the "A Better Installer" splash screen (adds a whopping 100KB)
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    66
  !define XPUI_SETUP_SPLASH
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    67
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    68
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    69
; Variables
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    70
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    71
Var SMFOLDER
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    72
Var INSTALL_EX
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    73
Var INSTALL_DOCS
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    74
Var INSTALL_UTILS
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    75
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    76
!insertmacro XPUI_PAGE_STARTMENU_INIT App $SMFOLDER
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    77
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    78
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    79
; Version Info
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    80
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    81
VIProductVersion "1.11.${XPUI_BUILD_ID_DECIMAL}"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    82
VIAddVersionKey /LANG=1033 "FileVersion" "1.11.${XPUI_BUILD_ID}"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    83
VIAddVersionKey /LANG=1033 "ProductVersion" "1.11.${XPUI_BUILD_ID}"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    84
VIAddVersionKey /LANG=1033 "ProductName" "ExperienceUI for NSIS"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    85
VIAddVersionKey /LANG=1033 "Comments" "This installer was written by Dan Fuhry using Nullsoft Scriptable Install System (http://nsis.sourceforge.net)"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    86
VIAddVersionKey /LANG=1033 "CompanyName" "Dan Fuhry"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    87
VIAddVersionKey /LANG=1033 "LegalTrademarks" "ExperienceUI SDK by Dan Fuhry. Copyright © 2004-2005 Dashboard Software Ltd."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    88
VIAddVersionKey /LANG=1033 "LegalCopyright" "Copyright © 2004-2005 Dan Fuhry"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    89
VIAddVersionKey /LANG=1033 "FileDescription" "ExperienceUI SDK Setup/Maintenance Program"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    90
VIAddVersionKey /LANG=1033 "SpecialBuild" "ExperienceUI for NSIS Software Development Kit Setup, built on ${__TIMESTAMP__} (${XPUI_BUILD_ID})"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    91
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    92
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    93
; Initialization
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    94
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    95
Function .onInit
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    96
  !ifdef XPUI_SETUP_SPLASH
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    97
  InitPluginsDir
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    98
  SetOutPath $PLUGINSDIR
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    99
  File LargeLogo.gif
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   100
  newadvsplash::show /NOUNLOAD 2000 2000 2000 -1 "$PLUGINSDIR\LargeLogo.gif"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   101
  Delete $PLUGINSDIR\LargeLogo.gif
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   102
  !endif
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   103
  ReadRegStr $0 HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\NSIS" "UninstallString"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   104
  StrCpy $0 $0 "" 1
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   105
  StrCpy $0 $0 -17
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   106
  IfFileExists $0\MakeNSIS.exe FoundNSIS
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   107
    MessageBox MB_YESNO|MB_ICONEXCLAMATION "Setup was unable to find NSIS on your system.  The ExperienceUI SDK requires NSIS in order to function.$\n$\nDo you want to go to the NSIS website now?" IDNO +2
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   108
      ExecShell open "http://nsis.sourceforge.net/"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   109
    Abort
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   110
  FoundNSIS:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   111
  StrCpy $INSTDIR "$0\Contrib\ExperienceUI"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   112
FunctionEnd
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   113
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   114
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   115
; Sections
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   116
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   117
!verbose 0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   118
!include ExperienceUIFileList.nsh
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   119
Section
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   120
  ReadRegStr $0 HKLM "Software\Microsoft\Windows NT\CurrentVersion" "RegisteredOwner"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   121
  StrCmp $0 "Daniel C. Fuhry" +2
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   122
  MessageBox MB_OK|MB_ICONINFORMATION "Please take some time to read the ExperienceUI documentation because the ExperienceUI is different from other UIs and as a result requires a slightly different script layout."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   123
SectionEnd
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   124
!verbose 4
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   125
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   126
SubSection "Downloadable extras"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   127
  Section "Page background images - 187KB"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   128
    DetailPrint "Downloading file: http://xpui.sf.net/bin/1.11/bgimages.eup (187KB, <1min)"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   129
    download:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   130
    nsisdl::download_quiet "http://xpui.sourceforge.net/bin/1.11/bgimages.eup" "$PLUGINSDIR\bg.eup"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   131
    Pop $0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   132
    StrCmp $0 success dlgood
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   133
      MessageBox MB_OK|MB_ICONEXCLAMATION "Error downloading patch file: $0"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   134
      Return
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   135
    dlgood:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   136
    DCryptDll::MD5Hash "FS" "$PLUGINSDIR\bg.eup" "--End--"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   137
    Pop $0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   138
      StrCmp $0 OK ok1
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   139
      MessageBox MB_OK|MB_ICONSTOP "Error verifying MD5 hash of download:$\n$0"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   140
      Goto done
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   141
    ok1:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   142
    Pop $0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   143
    StrCmp $0 "83972708FD0EBC9373BDEF81EE006881" Patch ; Not the signature hash, just the regular MD5
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   144
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   145
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   146
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   147
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   148
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   149
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   150
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   151
      Pop $9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   152
      Pop $9 ; GET RID OF THE STACK!!!!
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   153
      StrCpy $0 ""
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   154
      StrCpy $1 ""
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   155
      StrCpy $2 ""
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   156
      StrCpy $3 ""
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   157
      StrCpy $4 ""
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   158
      messagebox::show MB_ICONEXCLAMATION|MB_TOPMOST|MB_DEFBUTTON1 "Bad Download" "0,103" "The ExperienceUI installer has detected that the MD5 hash of the official download and the hash of the downloaded file are different.$\n$\nThe most likely reason for this is a corrupt download.  If you want to try to download the file again, click Try Again.$\n$\nIt is also possible, though very unlikely, that someone has broken into the ExperienceUI web server and changed the patch file to something potentially malicious.  If you think that is the case, please press Skip.$\n$\nTo try to install the patch file anyway, click Ignore.$\n" "IDTRYAGAIN" "Skip" IDIGNORE
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   159
      Pop $1
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   160
      StrCmp $1 1 download
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   161
      StrCmp $1 2 done
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   162
    Patch:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   163
      DetailPrint "Installing background image files..."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   164
      ExecWait '"$INSTDIR\Utils\PatchInstaller.exe" $PLUGINSDIR\bg.eup /Silent'
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   165
    Done:
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   166
  SectionEnd
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   167
SubSectionEnd
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   168
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   169
!macro CM_UNINST
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   170
  Delete $INSTDIR\Utils\Updater.exe
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   171
  Delete $INSTDIR\Utils\PatchInstaller.exe
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   172
  SetOutPath "C:\" ; Reset the output dir and close any handles still open
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   173
  ${CMInclude} Dirlist # doing this three
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   174
  ${CMInclude} Dirlist # times to make sure
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   175
  ${CMInclude} Dirlist # everything's gone
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   176
  RMDir $INSTDIR # Will delete $INSTDIR if it's empty
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   177
!macroend
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   178
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   179
;-------------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   180
; Pages
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   181
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   182
!verbose 0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   183
!insertmacro CM_LANGUAGE English
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   184
!insertmacro CM_PAGES
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   185
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   186
!define XPUI_WELCOMEPAGE2_TEXT_TOP "Welcome to ExperienceUI 1.11."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   187
!define XPUI_WELCOMEPAGE2_TEXT     "Welcome to the ExperienceUI, the user interface that makes NSIS the installer your programs truly deserve.\r\n\r\nClick Next to start.\r\n\r\nThis release is version 1.11 and it was built on ${__TIMESTAMP__}."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   188
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   189
${Page} Welcome2
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   190
${LicensePage} License.rtf
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   191
${Page} Components
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   192
${Page} Directory
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   193
!insertmacro XPUI_PAGE_STARTMENU_SHOW App
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   194
${Page} InstConfirm
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   195
${Page} InstFiles
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   196
${Page} Finish
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   197
${Page} Abort
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   198
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   199
${UnPage} Welcome2
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   200
${UnPage} UnConfirm
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   201
${UnPage} InstConfirm
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   202
${UnPage} InstFiles
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   203
${UnPage} Finish
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   204
${UnPage} Abort
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   205
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   206
!insertmacro XPUI_LANGUAGE "English"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   207
!insertmacro CM_FILES
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
   208
!verbose 4