Install and next button texts should always be added when needed now.

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@1612 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
kichik 2002-11-07 15:50:30 +00:00
parent 848c1e4785
commit fd99a585a2
4 changed files with 15 additions and 2 deletions

View file

@ -292,6 +292,9 @@ CEXEBuild::CEXEBuild()
#ifdef NSIS_CONFIG_UNINSTALL_SUPPORT
build_uninst.common.num_pages=0;
#endif
build_custom_used=0;
ubuild_custom_used=0;
}
int CEXEBuild::getcurdbsize() { return cur_datablock->getlen(); }

View file

@ -204,6 +204,8 @@ class CEXEBuild {
StringList build_userlangstrings, ubuild_userlangstrings;
GrowBuf build_pages, ubuild_pages;
int build_custom_used, ubuild_custom_used;
MMapBuf build_datablock, ubuild_datablock; // use GrowBuf here instead of MMapBuf if you want
IGrowBuf *cur_datablock;

View file

@ -397,9 +397,15 @@ void CEXEBuild::FillDefaultsIfNeeded(StringTable *table, NLF *nlf/*=0*/) {
#endif
)
{
// Changed by Amir Szekely 22nd July 2002
// Adds the ability to disable space texts
if (!table->installer.spacerequired && !no_space_texts) table->installer.spacerequired=add_string_main(str(NLF_SPACE_REQ),0);
}
if (table->installer.text
#ifdef NSIS_CONFIG_COMPONENTPAGE
|| table->installer.componenttext
#endif
|| build_custom_used || ubuild_custom_used
)
{
if (!table->common.nextbutton) table->common.nextbutton=add_string_main(str(NLF_BTN_NEXT),0);
if (!table->installer.installbutton) table->installer.installbutton=add_string_main(str(NLF_BTN_INSTALL),0);
}

View file

@ -553,6 +553,7 @@ int CEXEBuild::doCommand(int which_token, LineParser &line, FILE *fp, const char
switch (k) {
case 0:
p.id = NSIS_PAGE_CUSTOM;
build_custom_used++;
break;
case 1:
#ifdef NSIS_CONFIG_LICENSEPAGE
@ -648,6 +649,7 @@ int CEXEBuild::doCommand(int which_token, LineParser &line, FILE *fp, const char
switch (k) {
case 0:
p.id = NSIS_PAGE_CUSTOM;
ubuild_custom_used++;
break;
case 1:
p.id = NSIS_PAGE_UNINST;