if the first section was a section group, following section groups didn't behave correctly
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@3900 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
10330d6061
commit
282cd1ef72
4 changed files with 14 additions and 8 deletions
|
@ -34,7 +34,7 @@ void NSISCALL SectionFlagsChanged(unsigned int index) {
|
|||
}
|
||||
}
|
||||
|
||||
unsigned int NSISCALL RefreshSectionGroups(unsigned int i) {
|
||||
static unsigned int NSISCALL _RefreshSectionGroups(unsigned int i, int first_call) {
|
||||
unsigned int selected = 0;
|
||||
unsigned int not_selected = 0;
|
||||
|
||||
|
@ -43,8 +43,10 @@ unsigned int NSISCALL RefreshSectionGroups(unsigned int i) {
|
|||
unsigned int sec = i;
|
||||
|
||||
if (sections[sec].flags & SF_SECGRP) {
|
||||
sections[sec].flags &= ~(SF_SELECTED | SF_PSELECTED);
|
||||
i++;
|
||||
if (!first_call) {
|
||||
sections[sec].flags &= ~(SF_SELECTED | SF_PSELECTED);
|
||||
i++;
|
||||
}
|
||||
}
|
||||
|
||||
while (i < (unsigned int) num_sections) {
|
||||
|
@ -52,7 +54,7 @@ unsigned int NSISCALL RefreshSectionGroups(unsigned int i) {
|
|||
int ni = i + 1;
|
||||
|
||||
if (flags & SF_SECGRP) {
|
||||
ni = RefreshSectionGroups(i);
|
||||
ni = _RefreshSectionGroups(i, 0);
|
||||
}
|
||||
|
||||
if (flags & SF_SECGRPEND) {
|
||||
|
@ -84,6 +86,10 @@ unsigned int NSISCALL RefreshSectionGroups(unsigned int i) {
|
|||
return 0;
|
||||
}
|
||||
|
||||
void NSISCALL RefreshSectionGroups() {
|
||||
_RefreshSectionGroups(0, 1);
|
||||
}
|
||||
|
||||
void NSISCALL SetInstType(int inst_type) {
|
||||
unsigned int i = 0;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue