Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   Can I access "Space Required" on MUI_PAGE_DIRECTORY? (http://forums.winamp.com/showthread.php?t=274833)

darora2 23rd July 2007 22:20

Can I access "Space Required" on MUI_PAGE_DIRECTORY?
 
I want to add 100MB to the "Space Required" value on the MUI_PAGE_DIRECTORY, that gets displayed when the user selects the installation directory, so as to account for future updates to the installlation.
Any idea how I can access this value, and is it possible to change it and display at the same place?

Thanks in advance

kichik 23rd July 2007 22:31

Use AddSize.

pozbremser 3rd September 2007 10:36

Hi,

I habe some components, that can be choosen by user.
and some files, which I allways copy.

section 1 has 1 KB
section 2 has 2 KB
files have 3 KB

I use AddSize funktion in sections.
Space requed on component page is 3 (1+2)
Space requed on directory page is 3.
I want, space requed on directory page is 6 KB (1+2+3)
How can I show size on directory page?
shall I use SectionGetSize for earch section and add size of copied files (right plase for it is leave functjion)?
Or can I get the size as text from directory page and convert it to Integer,
add size of copied files,
and change label on directory page?

I used a special section for this, but if no section selected, requied space is 3 KB in this case, enduser can confused with it.

Thanks.

pozbremser 3rd September 2007 11:04

I created a section for this.
it works, but if one selects no components,
and click next, then back, space requed is changed.
Do I have to create a show function for components page,
and set size back?
or is there any elegant solution?

!define MUI_PAGE_CUSTOMFUNCTION_SHOW directoryPageShow
!insertmacro MUI_PAGE_DIRECTORY

Section -copydatasize copydata size_id
; see directoryPageShow
;AddSize 25686
SectionEnd

Function directoryPageShow
SectionSetSize ${copydatasize_id} 25686
FunctionEnd

Thanks.


All times are GMT. The time now is 04:34.

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.