Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   Hidden sections within Section Groups (http://forums.winamp.com/showthread.php?t=230611)

flyakite 10th November 2005 05:37

Hidden sections within Section Groups
 
If I dynamically change a sections text to "" to hide the section, if the Section Group it is in is checked, does it also check the hidden section?

I want to make sure that if I dynamically hide a section (say because the needed files don't exist on the users system), I want to make sure that if the SectionGroup it is located within does not still try installing that section when it is hidden.

JasonFriday13 10th November 2005 05:42

If a section is hidden, I believe it will always be executed.

Edit: Well then, I have to hand you over to someone else as I don't know anything more on sections or section groups.

flyakite 10th November 2005 06:07

Well ALL of my sections already have the /o switch in front of them, so by default my installer has no sections checked.

Animaether 10th November 2005 12:15

basic answer: yes

The text of a section is separate of its flags, and any subgroup/item - even if hidden - still gets selected/deseleted if the parent gets selected/deselected.

Which means you basically have to add the following to the top of the sections that may get hidden;
PHP Code:

  SectionGetText ${sectionID} $0
  StrCmp 
$"" +2
    Abort 

Where 'sectionID' needs to be replaced with whatever the ID of the section in question is.


All times are GMT. The time now is 17:55.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.