[Gpg4win-commits] r81 - in trunk: . src
scm-commit at wald.intevation.org
scm-commit at wald.intevation.org
Tue Nov 29 13:07:51 CET 2005
Author: werner
Date: 2005-11-29 13:07:51 +0100 (Tue, 29 Nov 2005)
New Revision: 81
Modified:
trunk/ChangeLog
trunk/src/inst-sections.nsi
trunk/src/installer.nsi
Log:
Autoselect the keymanager to start
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2005-11-29 10:50:24 UTC (rev 80)
+++ trunk/ChangeLog 2005-11-29 12:07:51 UTC (rev 81)
@@ -7,6 +7,9 @@
* packages/download.sh: Rewritten.
* src/inst-sections.nsi (.onInstFailed, .onInstSuccess): New.
+ (RunOnFinish): New function to run a key manager depending on the
+ installed ones.
+ * src/installer.nsi: Use a function to run the key manager on finish.
2005-11-28 Werner Koch <wk at g10code.com>
Modified: trunk/src/inst-sections.nsi
===================================================================
--- trunk/src/inst-sections.nsi 2005-11-29 10:50:24 UTC (rev 80)
+++ trunk/src/inst-sections.nsi 2005-11-29 12:07:51 UTC (rev 81)
@@ -381,6 +381,28 @@
FunctionEnd
+# This function is run from the finish page.
+Function RunOnFinish
+!ifdef HAVE_PKG_GPA
+ SectionGetFlags ${SEC_gpa} $R0
+ IntOp $R0 $R0 & ${SF_SELECTED}
+ IntCmp $R0 ${SF_SELECTED} 0 no_gpa_avail
+ Exec "$INSTDIR\gpa.exe"
+ Return
+ no_gpa_avail:
+!endif
+!ifdef HAVE_PKG_WINPT
+ SectionGetFlags ${SEC_winpt} $R0
+ IntOp $R0 $R0 & ${SF_SELECTED}
+ IntCmp $R0 ${SF_SELECTED} 0 no_winpt_avail
+ Exec "$INSTDIR\WinPT.exe --keymanager"
+ Return
+ no_winpt_avail:
+!endif
+ MessageBox MB_OK "$(T_NoKeyManager)"
+FunctionEnd
+
+
# This must be in a central place. Urgs.
!insertmacro MUI_FUNCTION_DESCRIPTION_BEGIN
Modified: trunk/src/installer.nsi
===================================================================
--- trunk/src/installer.nsi 2005-11-29 10:50:24 UTC (rev 80)
+++ trunk/src/installer.nsi 2005-11-29 12:07:51 UTC (rev 81)
@@ -92,7 +92,6 @@
#!define MUI_LANGDLL_REGISTRY_KEY "Software\GNU\${PRETTY_PACKAGE_SHORT}"
#!define MUI_LANGDLL_REGISTRY_VALUENAME "Installer Language"
-
# The list of wizard pages.
!define MUI_WELCOMEPAGE_TITLE "$(T_WelcomeTitle)"
@@ -109,6 +108,7 @@
!ifdef HAVE_STARTMENU
Var STARTMENU_FOLDER
+
!define MUI_STARTMENUPAGE_REGISTRY_ROOT "HKCU"
!define MUI_STARTMENUPAGE_REGISTRY_KEY "Software\GNU\${PRETTY_PACKAGE_SHORT}"
!define MUI_STARTMENUPAGE_REGISTRY_VALUENAME "Start Menu Folder"
@@ -119,8 +119,8 @@
!define MUI_PAGE_CUSTOMFUNCTION_PRE PrintCloseOtherApps
!insertmacro MUI_PAGE_INSTFILES
-!define MUI_FINISHPAGE_RUN "$INSTDIR\gpa.exe"
-!define MUI_FINISHPAGE_RUN_PARAMETERS "--keyring"
+!define MUI_FINISHPAGE_RUN
+!define MUI_FINISHPAGE_RUN_FUNCTION RunOnFinish
!define MUI_FINISHPAGE_RUN_TEXT "$(T_RunKeyManager)"
!define MUI_FINISHPAGE_RUN_NOTCHECKED
!define MUI_FINISHPAGE_LINK "$(T_MoreInfo)"
@@ -194,7 +194,13 @@
LangString T_MoreInfo ${LANG_GERMAN} \
"Hier klicken um zur Homepage des Projekts zu gelangen"
+LangString T_NoKeyManager ${LANG_ENGLISH} \
+ "No key manager has been installed, thus we can't run one now."
+LangString T_NoKeyManager ${LANG_GERMAN} \
+ "Es wurde keine Schlüsselverwaltung installiert. \
+ Deswegen kann sie jetzt auch nicht ausgeführt werden."
+
# Functions
# Custom functions and macros for gpg4win.
More information about the Gpg4win-commits
mailing list