Winamp & Shoutcast Forums

Winamp & Shoutcast Forums (http://forums.winamp.com/index.php)
-   NSIS Discussion (http://forums.winamp.com/forumdisplay.php?f=65)
-   -   hide the back button (http://forums.winamp.com/showthread.php?t=230179)

M4RC II 5th November 2005 15:42

hide the back button
 
hy i've make a custom page and now I would hide the back button. How can I do this ?

Thx

Afrow UK 5th November 2005 17:29

Page Custom CreateFunc
!include WinMessages.nsh

Function CreateFunc
GetDlgItem $R0 $HWNDPARENT 3
ShowWindow $R0 ${SW_HIDE}
!insertmacro MUI_INSTALLOPTIONS_DISPLAY "ioFile.ini"
FunctionEnd

-Stu

M4RC II 5th November 2005 18:33

Hy thx it works.

I've further two other questions:

1. Right above is the symbol close. Can I deactivate this as maximize?

2. How can I hide the back button from the finish page ?

Thank you

Animaether 5th November 2005 22:22

1. You'd have to change the window styles using the System plugin. edit: I don't think you can, actually - once the window has been created, I don't think you can change its style.

2. Using much the same method as you did Afrow showed before. If you are using the Modern UI:
PHP Code:

!define MUI_PAGE_CUSTOMFUNCTION_PRE FinishPre
!insertmacro MUI_PAGE_FINISH

Function FinishPre
  GetDlgItem $R0 $HWNDPARENT 3
  ShowWindow $R0 
${SW_HIDE}
FunctionEnd 


M4RC II 6th November 2005 07:32

Hy thx for your help. My last question:

Is it possible only to disable (not hide) a button?

Thank you to all who help me.

Animaether 6th November 2005 08:07

Yes,

PHP Code:

  GetDlgItem $R0 $HWNDPARENT 3 
  ShowWindow $R0 
${SW_HIDE

would become
PHP Code:

  GetDlgItem $R0 $HWNDPARENT 3 
  EnableWindow $R0 0
|# 0=hide, 1=show 


M4RC II 6th November 2005 09:09

Thx animaether it works.

:rolleyes: i know i've write that it was my last question but how can i disable the cancel button?

Thank you:)

Animaether 6th November 2005 12:21

PHP Code:

# next button
GetDlgItem $R0 $HWNDPARENT 1
# cancel button
GetDlgItem $R0 $HWNDPARENT 2
# back button
GetDlgItem $R0 $HWNDPARENT 3 

You can use utilities such as WinSpy++ to get these numbers (Control IDs) from a dialog;
http://www.catch22.net/software/winspy.asp


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

Copyright © 1999 - 2010 Nullsoft. All Rights Reserved.