- NSIS Discussion
- A bug and a question..
Archive: A bug and a question..
mgillespie
18th July 2003 17:01 UTC
A bug and a question..
First the bug:
Latest CVS has a problem with the latest MUI. The Reboot dialog has incorrect background colours for the reboot now, manual reboot text.
CVS from a few days ago is fine.
Now the question:
I have the following custom dialog:
http://www.broadband4preston.org.uk/keyfile.JPG
As you can see, I have my Copy code implemented in the "next", this works fine, but I'm having a problem in the "skip" button, this is the Cancel action. Obviously this aborts the install completly. I want to skip to the next dialog. Can this be done. I have tried allsorts, without any luck.
kichik
18th July 2003 17:04 UTC
You can't get the cancel button to skip the page, it only cancels. Nice picture btw ;)
mgillespie
18th July 2003 17:04 UTC
I don't know if the picture is showing on this message (it's not for me). You can see the custom dialog in question here:
http://www.broadband4preston.org.uk/keyfile.JPG
Afrow UK
18th July 2003 17:04 UTC
You need to move your code from your next function to here:
Function CustomDialog
InstallOptions::dialog "mydialog.ini"
Pop $R0
StrCmp $R0 cancel exitpage
myfunction:
##do you're next function ere###
exitpage:
FunctionEnd
-Stu
mgillespie
18th July 2003 17:06 UTC
Do you have any other ideas what I can do to accomplish this?
Afrow UK
18th July 2003 17:06 UTC
Ok, never mind.
The cancel button can't do that.
Afrow UK
18th July 2003 17:07 UTC
Actually, put "Abort" after "exitpage:" in that function.
-Stu
kichik
18th July 2003 17:10 UTC
On second thought, you can use the same method that I suggested in this recent thread:
http://forums.winamp.com/showthread....ht=back+button
Just send that message if you get cancel from IO.
mgillespie
18th July 2003 17:12 UTC
I'm kinda stuck, as the MUI does not allow me to place buttons on it (if I could do this, I could have a dedicated Copy button, and leave next and cancel as they are).
Looking for inspiration on what to do now.
kichik
18th July 2003 17:21 UTC
Take a look at the script I linked to in my last post.
mgillespie
18th July 2003 17:32 UTC
Not working yet...
Here is my code..
Push $CustomDialogKeyPress
InstallOptions::dialog "$PLUGINSDIR\rtx.ini"
Pop $CustomDialogKeyPress
;process the return from the dialog
StrCmp $CustomDialogKeyPress "cancel" CancelPressed
StrCmp $CustomDialogKeyPress "back" GoodKeyCopy
CancelPressed:
; sending this OK message (is this too late???)
SendMessage $HWNDPARENT ${WM_COMMAND} ${IDOK} 0
GoodKeyCopy:
Joost Verburg
18th July 2003 17:33 UTC
Thanks. Fixed the bug :)
kichik
18th July 2003 17:43 UTC
That would be the quit flag doing its work. I'll let you know if I have another idea.
mgillespie
18th July 2003 18:14 UTC
Thanks. It turns out the SendMessage is a nogo for the Cancel, as it's already in the process of quitting.
I have inplemented it on the "back" and kichik SendMessage trick works fine.
Thanks.