Examples/ExperienceUI/HeaderBitmap.nsi
author Dan
Thu, 17 Dec 2009 05:32:39 -0500
changeset 19 6c9560a32dc7
parent 13 2ae1abe546fd
permissions -rwxr-xr-x
Added Portuguese (2070) translation. Thanks Adriano Pereira!
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
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     2
;Header Bitmap Example Script
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     3
;Written by Dan Fuhry
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
;OK, I cheated, Joost wrote it :)
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     6
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     7
;--------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     8
;Include ExperienceUI
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
     9
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    10
  !include "XPUI.nsh"
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
;--------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    13
;General
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
  ;Name and file
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    16
  Name "ExperienceUI Test"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    17
  OutFile "HeaderBitmap.exe"
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
  ;Default installation folder
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    20
  InstallDir "$PROGRAMFILES\ExperienceUI Test"
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
  ;Get installation folder from registry if available
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    23
  InstallDirRegKey HKCU "Software\ExperienceUI Test" ""
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
;--------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    26
;Interface Configuration
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    27
13
2ae1abe546fd Updated all examples for detached installation compatibility
Dan
parents: 0
diff changeset
    28
  !define XPUI_HEADERIMAGE "${XPUI_SYSDIR}\Skins\Windows XP\Header.bmp"
0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    29
  ; might as well do a bottom image as well...
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    30
  !define XPUI_BOTTOMIMAGE ;we don't have to define a custom bottom image, the default is fine.
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    31
  !define XPUI_ABORTWARNING
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    32
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    33
;--------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    34
;Pages
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    35
13
2ae1abe546fd Updated all examples for detached installation compatibility
Dan
parents: 0
diff changeset
    36
  !insertmacro XPUI_PAGE_LICENSE "${XPUI_SYSDIR}\License.rtf"
0
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    37
  !insertmacro XPUI_PAGE_COMPONENTS
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    38
  !insertmacro XPUI_PAGE_DIRECTORY
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    39
  !insertmacro XPUI_PAGE_INSTFILES
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    40
  
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    41
  !insertmacro XPUI_PAGEMODE_UNINST
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    42
  !insertmacro XPUI_PAGE_UNINSTCONFIRM_NSIS
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    43
  !insertmacro XPUI_PAGE_INSTFILES
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    44
  
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    45
;--------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    46
;Languages
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    47
 
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    48
  !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
    49
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    50
;--------------------------------
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    51
;Installer Sections
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    52
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    53
Section "Dummy Section" SecDummy
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
  SetOutPath "$INSTDIR"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    56
  
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    57
  ;ADD YOUR OWN FILES HERE...
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
  ;Store installation folder
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    60
  WriteRegStr HKCU "Software\ExperienceUI Test" "" $INSTDIR
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
  ;Create uninstaller
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    63
  WriteUninstaller "$INSTDIR\Uninstall.exe"
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
SectionEnd
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    66
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
;Descriptions
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    69
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    70
  ;Language strings
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    71
  LangString DESC_SecDummy ${LANG_ENGLISH} "A test section."
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    72
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    73
  ;Assign language strings to sections
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    74
  !insertmacro XPUI_FUNCTION_DESCRIPTION_BEGIN
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    75
    !insertmacro XPUI_DESCRIPTION_TEXT ${SecDummy} $(DESC_SecDummy)
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    76
  !insertmacro XPUI_FUNCTION_DESCRIPTION_END
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
;Uninstaller Section
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
Section "Uninstall"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    82
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    83
  ;ADD YOUR OWN FILES HERE...
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    84
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    85
  Delete "$INSTDIR\Uninstall.exe"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    86
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    87
  RMDir "$INSTDIR"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    88
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    89
  DeleteRegKey /ifempty HKCU "Software\ExperienceUI Test"
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    90
d5ce4c64ef88 Initial population with stock ExUI 1.11pre + a couple of fixes needed to compile the installer
Dan
parents:
diff changeset
    91
SectionEnd