WINAMP.COM | Forums > Developer Center > NSIS Discussion > NSIS Logic Library |
Last Thread
Next Thread
|
| Author |
|
|
dselkirk Senior Member
Registered: Aug 2002 |
Hey, Here is another library to simplify the creation of your installs. This is the result of the previous post entitled "Select Statements". Thanks to eccles I have been able to completely rewrite it with improved functionality and speed.
|
||
|
|
|
eccles NSIS Dev
Registered: Sep 2001 |
Hey Don, check your private messages...! |
||
|
|
|
dselkirk Senior Member
Registered: Aug 2002 |
Version 2.1 adds break and continue labels to repeat type statements. Useful for functions like MessageBox, here is an example: code: Thanks to eccles for the idea.
|
||
|
|
|
kichik M.I.A. [NSIS Dev, Mod]
Registered: Oct 2001 |
Damn, that's so cool! __________________ |
||
|
|
|
eccles NSIS Dev
Registered: Sep 2001 |
Don, I've made a couple of changes for your perusal.
|
||
|
|
|
dselkirk Senior Member
Registered: Aug 2002 |
Good work on the consolidation and fixes. I especially love your solution for the operation comparison in the foreach statement. Very nice. What were the issues with the break and continue labels? For the if..then statments I had to add some extra lines to handle just an if..else..endif statements. When I had something like the foloowing: code: Both messages would appear. It wasn't moving to the end. Here it is again with the updated file header.
|
||
|
|
|
fraefel Junior Member
Registered: Mar 2003 |
Hi eccles & dselkirk! |
||
|
|
|
eccles NSIS Dev
Registered: Sep 2001 |
NSIS LogicLib Version 2.3
|
||
|
|
|
eccles NSIS Dev
Registered: Sep 2001 |
NSIS LogicLib Version 2.4
|
||
|
|
|
kichik M.I.A. [NSIS Dev, Mod]
Registered: Oct 2001 |
I love it! __________________ |
||
|
|
|
CodeSquid Member
Registered: Dec 2001 |
Great stuff! Truly amazing! What dou you come up with next? A NSIS compiler written in NSIS? |
||
|
|
|
Joost Verburg NSIS MUI Dev
Registered: Nov 2001 |
These things will become possible when NSIS supports compiler plug-ins. |
||
|
|
|
CodeSquid Member
Registered: Dec 2001 |
Compiler plugins? Whoah, any ETA? |
||
|
|
|
Joost Verburg NSIS MUI Dev
Registered: Nov 2001 |
NSIS 2.1 |
||
|
|
|
eccles NSIS Dev
Registered: Sep 2001 |
Thanks all for the thanks |
||
|
|
|
eccles NSIS Dev
Registered: Sep 2001 |
New in CVS: LogicLib v2.5 __________________ |
||
|
|
|
rsegal Senior Member
Registered: Feb 2003 |
eccles this logic library is amazing. I've converted some of my scripts to use it and have been able to eliminate huge chunks of script because of it. Thanks alot man! __________________ |
||
|
|
|
Animaether Major Dude
Registered: Jun 2001 |
small question... can you not use LogicLib inside of macros with passed variables ? Tells me: !insertmacro: macro "_If" requires 4 parameter(s), passed 3! |
||
|
|
|
Animaether Major Dude
Registered: Jun 2001 |
nevermind... it's fine.. And that throws the error. Apparently because once inside the macro, "" becomes <null>. Weird. Work-arounds? That would kill any integer checks, though. Seems to work - is that the proper way to go about this ? I'm a bit confused as to why an empty string becomes null if passed to a macro, though. In the latter bit, my string consisting of two quotation marks essentially becomes an empty string?
|
||
|
|
|
kichik M.I.A. [NSIS Dev, Mod]
Registered: Oct 2001 |
Quoting in the ${If} line is the correct way to get around this. Why would it kill any integer checks? __________________ |
||
|
|
|
Animaether Major Dude
Registered: Jun 2001 |
because I'm making the gross assumption that you can't compare a string to an int :x |
||
|
|
|
kichik M.I.A. [NSIS Dev, Mod]
Registered: Oct 2001 |
But an integer is a string in NSIS. Commands that require integers automatically convert the string to an integer. __________________ |
||
|
|
|
mamilo Junior Member
Registered: Nov 2006 |
Hi, |
||
|
|
|
bholliger Senior Member
Registered: Jul 2004 |
Hi mamilo! |
||
|
|
|
Comperio Major Dude
Registered: Jan 2005 |
Shouldn't it be this? code: |
||
|
|
|
bholliger Senior Member
Registered: Jul 2004 |
I think the code is correct. |
||
|
|
|
phunkydizco Junior Member
Registered: Jul 2005 |
How do I use the OrUnless Statement correctly? I want to do something when one of two sections is selected. Here is my code that doesn't work: code: |
||
|
|
|
Anders Major Dude
Registered: Jun 2002 |
only one "if" statement per line __________________ |
||
|
|
|
phunkydizco Junior Member
Registered: Jul 2005 |
Is this correct? code: |
||
|
|
|
Afrow UK Moderator
Registered: Nov 2002 |
You can just use the ${If} ${SelectionIsSelected} ... ${OrIf} ${SelectionIsSelected} ... __________________ |
||
|
|
|
Animaether Major Dude
Registered: Jun 2001 |
besides what Afrow said - yes, that'd be correct |
||
|
|
|
phunkydizco Junior Member
Registered: Jul 2005 |
|
||
|
|
|
Afrow UK Moderator
Registered: Nov 2002 |
Why? __________________ |
||
|
|
|
phunkydizco Junior Member
Registered: Jul 2005 |
That's right I didn't see that. But my code is also ok? |
||
|
|
|
Afrow UK Moderator
Registered: Nov 2002 |
It may work but the proper logic is to check if ${SF_SELECTED} (1) is set: __________________ |
||
|
|
|
phunkydizco Junior Member
Registered: Jul 2005 |
What does this line? |
||
|
|
|
Last Thread Next Thread
|
WINAMP.COM | Forums > Developer Center > NSIS Discussion > NSIS Logic Library |
Forum Rules:
|