Comm@nder21
13th December 2004 17:24 UTC
animate bgimage - how to get handle?
i'm trying to animate bgimage using this command:
System::Call "user32::AnimateWindow(i $HWNDPARENT, i '500', i '${AW_HIDE}|${AW_BLEND}') i."
of course, $HWNDPARENT only works with the nsis window itself.
win32spy told me that the window class is "NSISBGImage", so i tried the following code:
Push $0
FindWindow $0 "NSISBGImage"
StrCmp $0 "0" +2
System::Call "user32::AnimateWindow(i $0, i '500', i '${AW_HIDE}|${AW_BLEND}') i."
Pop $0
BgImage::Destroy
but didn't work.
and, yes, i defined the flags correctly, works with the main window :)
anyone could help me getting the handle to the backround image?
Comm@nder21
14th December 2004 16:15 UTC
noone any idea?
DrO
14th December 2004 17:44 UTC
have you looked at the code for bgimage to see how it creates the window and to then go from there? (i'd look if i had access to the source myself but tricky to do at work :( )
-daz
kichik
14th December 2004 18:39 UTC
Comm@nder21, if you pass a number, it shouldn't be in quotes. Quotes are only for strings.
DrO, the source is always accessible ;)
Comm@nder21
14th December 2004 21:23 UTC
@dro: i'm sry, my skills are not enough in c++ to understand the code. i tried it :)
@kichik: the system call itself works fine for me, but only with $HWNDPARENT as handle (so, for the main installer window).
DrO
14th December 2004 21:26 UTC
kichik: that's true but it's a bit tricky to view it when you're not meant to be looking at code ;)
Comm@nder21: my bad, you seemed to know what you were doing with the system plugin so i sort of assumed you knew c/c++
-daz
Comm@nder21
14th December 2004 21:29 UTC
indeed i've some very low skills in c++, not enough to write somethin really usefull, though.
so, the nsis scripting language and the way, the system plugin handles api calls is not that complicated than it's in c++.
atleast a basic understanding of code itself i really do have, but not enough for that case.
so, if anyone could read the code for me and get the answer, i'd be really happy :)
DrO
14th December 2004 21:31 UTC
i'll try and have a scan through in a bit for you :)
-daz
Comm@nder21
16th December 2004 14:49 UTC
found something, dro?