Hi,
I noticed that all clips are correct, except the last one
cx.setClip(0,32,25,-500)
where you forgot the []

I think you're probably still used to the DynAPI1 system, as one doesn't
often use setClip() manually in DynAPI2, except for certain effects.
but then, there are a 1000 ways to do everything.

Cheers,
Richard Bennett

[EMAIL PROTECTED]
www.richardinfo.com
(Everything running on, and ported to the 19/12/2000 snapshot of DynAPI2)
visit the DynAPI homepage (and FAQ) ::
http://dynapi.sourceforge.net/dynapi/index.php?menu=1
Browse (and search) the mailinglist here:
http://www.mail-archive.com/index.php3?hunt=dynapi

----- Original Message -----
From: "Zambra - Michael" <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>
Sent: Thursday, April 05, 2001 8:05 PM
Subject: [Dynapi-Help] Hello and a problem with clip and eventlisteners


>
> Hello to all,
>
> I'm a newbie to DynAPI2. I had been working with DynAPI1 for a while, and
it
> is hard for me to get used to the concept of this new version. For
starters
> I have some difficulties with parent-child layers. I need to create a
group
> of seven layers, each one being the child of the preceding. Like this:
>
>
> ===snip starts
> DynAPI.setLibraryPath(../src/lib/')
>
> DynAPI.include('dynapi.api.*')
>
>
> DynAPI.onLoad=function() {
>
>   ccuadro = new DynLayer(null,100,50,660,78,'#FFCCFF')
>   ccuadro.setClip([14,546,78,0])
>   cmenu = new DynLayer(null,500,14,46,25,'#FF00FF')
>   cmenu.setClip([0,46,25,0])
>   cmenu.setHTML('<a href="javascript:open()"><img src="img/menu.gif"
> width="46" height="25" border="0" name="ccuadroi"></a>')
>   cenglish = new DynLayer(null,495,0,50,39,'#CCCCFF')
>   cenglish.setClip([0,50,39,0])
>   cenglish.setHTML('<a href="/intro_e.html"><img src="img/english.gif"
> width="50" height="39" border="0" name="cenglishi"></a>')
>   cacerca = new DynLayer(null,495,14,135,25,'#FFCCCC')
>   cacerca.setClip([0,135,25,-500])
>   cacerca.setHTML('<a href="/acerca.html"><img src="img/acercade.gif"
> width="135" height="25" border="0" name="cacercai"></a>')
>   cartistas = new DynLayer(null,0,0,71,25,'#00CCFF')
>   cartistas.setClip([0,71,25,-500])
>   cartistas.setHTML('<a href="./artistas/index.html"><img
> src="img/artistas.gif" width="71" border="0" height="25"
> name="cartistasi"></a>')
>   cparticipa = new DynLayer(null,0,0,93,25,'#0000FF')
>   cparticipa.setClip([0,93,25,-500])
>   cparticipa.setHTML('<a href="/participaciones.html"><img
> src="img/participaciones.gif" width="93" height="25" border="0"
> name="cparticipai"></a>')
>   ccontacto = new DynLayer(null,0,0,57,25,'#33CCFF')
>   ccontacto.setClip([0,57,25,-500])
>   ccontacto.setHTML('<img src="img/contacto1.gif" width="57" height="25"
> border="0" name="ccontactoi">')
>   cportada = new DynLayer(null,0,0,52,25,'#FF33FF')
>   cportada.setClip([0,52,25,-500])
>   cportada.setHTML('<a href="/intro.html"><img src="img/portada.gif"
> width="52" height="25" border="0" name="cportadai"></a>')
>   cx = new DynLayer(null,0,0,32,25,'#FFCC33')
>   cx.setClip(0,32,25,-500)
>   cx.setHTML('<a href="javascript:close()"><img src="img/x.gif" width="32"
> height="25" border="0" name="cxi"></a>')
>
>
>   DynAPI.document.addChild(ccuadro)
>   ccuadro.addChild(cmenu)
>   ccuadro.addChild(cenglish)
>   ccuadro.addChild(cacerca)
>   cacerca.addChild(cartistas)
>   cartistas.addChild(cparticipa)
>   cparticipa.addChild(ccontacto)
>   ccontacto.addChild(cportada)
>   cportada.addChild(cx)
>
> }
>
> This ultra-simple thing works with IE5, but not with NN 4.72. This
complains
> about a non-existing "clip" function. I feel quite stupid, because this is
> the basic-basic. What have I done wrong.
>
> Besides, how can I create an EventListener (simple mouse over-out) for all
> the layers. With a loop?
>
> Thanks in advance for your help.
>
> Miguel
>
>
> _______________________________________________
> Dynapi-Help mailing list
> [EMAIL PROTECTED]
> http://lists.sourceforge.net/lists/listinfo/dynapi-help
>


_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help

Reply via email to