Added SmalltalkStartup class
For historical reasons, IDE startup is not actually implemented as
a StandaloneStartup class as for Smalltalk/X-based applications.
Instead, the Smalltalk>>start reads smalltalk.rc and startup procedure
is defined there.
In order to reduce a number of .rc script hackery, functionality will be
incrementally moved from those scripts to this class and scripts will be
changed to call methods in this class. Eventually we will reach the point
when scripts will be empty and all functionality will be here. Let's hope.
; $Header$
; Script generated by ProjectDefinition.
!define PRODUCT_NAME "Smalltalk/X"
!define PRODUCT_FILENAME "SmalltalkX"
!define PRODUCT_VERSION "6.2.5.0"
!define PRODUCT_PUBLISHER "eXept Software AG"
!define PRODUCT_WEB_SITE "http://www.exept.de"
!define PRODUCT_UNINST_KEY "Software\Microsoft\Windows\CurrentVersion\Uninstall\${PRODUCT_FILENAME}"
!define PRODUCT_UNINST_ROOT_KEY "HKLM"
;
; SETUP_NAME can come from makefile as either setup or setup64
;
!if "${SETUP_NAME}" == ""
SETUP_NAME="Smalltalk/XSetup"
!endif
!define STX_ROOT "..\..\.."
SetCompressor /solid lzma
!include "MUI2.nsh"
!include "x64.nsh"
; MUI Settings
!define MUI_WELCOMEPAGE_TITLE_3LINES
!define MUI_ABORTWARNING
;; !define MUI_ICON "${NSISDIR}\Contrib\Graphics\Icons\modern-install.ico"
!define MUI_ICON "stx_32x32.ico"
;; !define MUI_UNICON "${NSISDIR}\Contrib\Graphics\Icons\modern-uninstall.ico"
!define MUI_UNICON "stx_32x32.ico"
; Language Selection Dialog Settings
!define MUI_LANGDLL_REGISTRY_ROOT "${PRODUCT_UNINST_ROOT_KEY}"
!define MUI_LANGDLL_REGISTRY_KEY "${PRODUCT_UNINST_KEY}"
!define MUI_LANGDLL_REGISTRY_VALUENAME "NSIS:Language"
; Welcome page
!insertmacro MUI_PAGE_WELCOME
; License page
; !define MUI_LICENSEPAGE_CHECKBOX
!insertmacro MUI_PAGE_COMPONENTS
; Directory page
!insertmacro MUI_PAGE_DIRECTORY
; Instfiles page
!insertmacro MUI_PAGE_INSTFILES
; Finish page
!insertmacro MUI_PAGE_FINISH
; Uninstaller pages
!insertmacro MUI_UNPAGE_INSTFILES
; Language files
!insertmacro MUI_LANGUAGE "English"
!insertmacro MUI_LANGUAGE "German"
; MUI end ------
Name "${PRODUCT_NAME} ${PRODUCT_VERSION}"
VIProductVersion "${PRODUCT_VERSION}.0"
VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductName" "${PRODUCT_NAME}"
VIAddVersionKey /LANG=${LANG_ENGLISH} "CompanyName" "${PRODUCT_PUBLISHER}"
VIAddVersionKey /LANG=${LANG_ENGLISH} "FileVersion" "6.2.32767.32767"
VIAddVersionKey /LANG=${LANG_ENGLISH} "FileDescription" "${PRODUCT_NAME} Installer"
VIAddVersionKey /LANG=${LANG_ENGLISH} "ProductVersion" "${PRODUCT_VERSION}"
VIAddVersionKey /LANG=${LANG_ENGLISH} "LegalCopyright" "Copyright Claus Gittinger 1988-2012\nCopyright eXept Software AG 1998-2012"
OutFile "${SETUP_NAME}.exe"
InstallDir "$PROGRAMFILES\stx"
ShowInstDetails show
ShowUnInstDetails show
Function .onInit
!insertmacro MUI_LANGDLL_DISPLAY
FunctionEnd
InstType Full
InstType Partial
Section "Programme" Section1
SectionIn 1 2
SetOutPath "$INSTDIR\bin"
SetOverwrite ifnewer
File "stx.exe" "stx.com"
File "*.dll"
File "symbols.stc"
File "*.stx"
File "*.rc"
File /r /x CVS /x ".*" resources
WriteRegStr HKCR "Stx.SmalltalkX.1" "" "SmalltalkX File"
WriteRegStr HKCR "Stx.SmalltalkX.1\DefaultIcon" "" '$INSTDIR\bin\stx.exe,0'
WriteRegStr HKCR "Stx.SmalltalkX.1\Shell\open" "" $(appOpen)
WriteRegStr HKCR "Stx.SmalltalkX.1\Shell\open\command" "" '"$INSTDIR\bin\stx.exe" -- "%1"'
SectionEnd
;; Section "Online-Documentation for Smalltalk/X" Section2
;; SectionIn 1
;; SetOutPath "$INSTDIR\doc"
;; SetOverwrite ifnewer
;; File /r /x CVS "${STX_ROOT}\stx\smalltalk\doc\*"
;; SectionEnd
;; Section "Smalltalk/X Libraries and Demos" Section3
;; SectionIn 1
;; SetOutPath "$INSTDIR\lib"
;; SetOverwrite ifnewer
;; ; File /r /x CVS "${STX_ROOT}\stx\smalltalk\examples\*"
;; SectionEnd
;;
;; Section "Smalltalk/X Reports and Printing" Section4
;; SectionIn 1
;; SetOutPath "$INSTDIR\reportGenerator"
;; SetOverwrite ifnewer
;; ; File /r /x CVS "..\reportGenerator\java" "..\reportGenerator\rules" "..\reportGenerator\*.xml" "..\reportGenerator\*.xslt" "..\reportGenerator\CloseApp.exe" "..\reportGenerator\expecco.jpg"
;; SectionEnd
Section -AdditionalIcons
SetOutPath "$INSTDIR\bin"
WriteIniStr "$INSTDIR\${PRODUCT_FILENAME}.url" "InternetShortcut" "URL" "${PRODUCT_WEB_SITE}"
CreateDirectory "$SMPROGRAMS\${PRODUCT_FILENAME}"
CreateShortCut "$SMPROGRAMS\${PRODUCT_FILENAME}\smalltalk.lnk" "$INSTDIR\bin\stx.exe"
CreateShortCut "$DESKTOP\smalltalk.lnk" "$INSTDIR\bin\stx.exe"
CreateShortCut "$SMPROGRAMS\${PRODUCT_FILENAME}\Website.lnk" "$INSTDIR\${PRODUCT_FILENAME}.url"
CreateShortCut "$SMPROGRAMS\${PRODUCT_FILENAME}\Uninstall.lnk" "$INSTDIR\uninst.exe"
SectionEnd
Section -Post
WriteUninstaller "$INSTDIR\uninst.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayName" "$(^Name)"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "UninstallString" "$INSTDIR\uninst.exe"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "DisplayVersion" "${PRODUCT_VERSION}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "URLInfoAbout" "${PRODUCT_WEB_SITE}"
WriteRegStr ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}" "Publisher" "${PRODUCT_PUBLISHER}"
SectionEnd
LangString appOpen ${LANG_GERMAN} "Mit Smalltalk/X ffnen"
LangString appOpen ${LANG_ENGLISH} "Open with Smalltalk/X"
LangString DESC_Section1 ${LANG_ENGLISH} "Program components of Smalltalk/X"
LangString DESC_Section1 ${LANG_GERMAN} "Alle Programmkomponenten von Smalltalk/X"
;; LangString DESC_Section2 ${LANG_ENGLISH} "Online-Documentation of Smalltalk/X"
;; LangString DESC_Section2 ${LANG_GERMAN} "Online-Dokumentation zu Smalltalk/X"
;; LangString DESC_Section3 ${LANG_ENGLISH} "Libraries and Demo Projects"
;; LangString DESC_Section3 ${LANG_GERMAN} "Bibliotheken und Beispielprojekte"
;; LangString DESC_Section4 ${LANG_ENGLISH} "Logfile Printing and Report Generation"
;; LangString DESC_Section4 ${LANG_GERMAN} "Drucken und Report-Generierung aus Log-Dateien"
;; LangString DESC_Section3 ${LANG_ENGLISH} "Sources of ST/X (Base-System)"
;; LangString DESC_Section3 ${LANG_GERMAN} "Quellcode von ST/X (Basis-System)"
;; LangString DESC_Section4 ${LANG_ENGLISH} "Sources of Smalltalk/X"
;; LangString DESC_Section4 ${LANG_GERMAN} "Quellcode von Smalltalk/X"
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
!insertmacro MUI_DESCRIPTION_TEXT ${Section1} $(DESC_Section1)
;; !insertmacro MUI_DESCRIPTION_TEXT ${Section2} $(DESC_Section2)
;; !insertmacro MUI_DESCRIPTION_TEXT ${Section3} $(DESC_Section3)
;; !insertmacro MUI_DESCRIPTION_TEXT ${Section4} $(DESC_Section4)
!insertmacro MUI_FUNCTION_DESCRIPTION_END
Function un.onUninstSuccess
HideWindow
MessageBox MB_ICONINFORMATION|MB_OK "Smalltalk/X wurde erfolgreich deinstalliert"
FunctionEnd
Function un.onInit
!insertmacro MUI_UNGETLANGUAGE
MessageBox MB_ICONQUESTION|MB_YESNO|MB_DEFBUTTON2 "Mchten Sie Smalltalk/X und alle seine Komponenten deinstallieren?" IDYES +2
Abort
FunctionEnd
Section Uninstall
Delete "$INSTDIR\${PRODUCT_FILENAME}.url"
Delete "$INSTDIR\uninst.exe"
Delete "$INSTDIR\*"
RMDir /r "$INSTDIR"
Delete "$SMPROGRAMS\${PRODUCT_FILENAME}\Uninstall.lnk"
Delete "$SMPROGRAMS\${PRODUCT_FILENAME}\Website.lnk"
Delete "$SMPROGRAMS\${PRODUCT_FILENAME}\smalltalk.lnk"
Delete "$DESKTOP\smalltalk.lnk"
RMDir "$SMPROGRAMS\${PRODUCT_FILENAME}"
DeleteRegKey ${PRODUCT_UNINST_ROOT_KEY} "${PRODUCT_UNINST_KEY}"
DeleteRegKey HKCR "Stx.SmalltalkX.1"
SetAutoClose true
SectionEnd