OK 

on rollover the correponding text clip fades in on rollout it fades out..

during debuging.. all of the targets are "text4" and it shouldnt  be..

clip0 should control text0 and etc..
but what happens is that clip0 to clip4 controls text4...
 
which is wrong, any suggestions?


Code below:

//this also sets the event handling in one shot
for (i=0; i<5; i++) {
    clipName = this["clip"+i];
    target= _root["text"+i]
    trace(target);


    clipName.onRollOver = function() {
        Tweener.addTween(this.person,{_alpha:100, delay:0, time:2});
        Tweener.addTween(this.whiteborder,{_alpha:100, delay:0, time:2});
        Tweener.addTween(target,{_alpha:100, delay:0, time:2});
        trace("onrollover"+target);

        
    };

    clipName.onRollOut = function() {
        Tweener.addTween(this.person,{_alpha:30, delay:0, time:1});
        Tweener.addTween(this.whiteborder,{_alpha:0, delay:0, time:1});
        Tweener.addTween(target,{_alpha:0, delay:0, time:2});
        
    };


}



> Date: Tue, 15 Jan 2008 21:32:41 -0800
> To: flashcoders@chattyfig.figleaf.com
> From: [EMAIL PROTECTED]
> Subject: Re: [Flashcoders] buttons lined up next to each other- rollout       
> not work
> 
> No such problem here with either adjacent or overlapping buttons. 
> Please post your code. Here's mine for four buttons named "btn1," "btn2," 
> etc.:
> 
> for (i = 1; i < 5; i++) {
>          this["btn" + i].onRollOut = function() {
>                  trace(this._name);
>          };
> }
> 
> Marc
> 
> At 09:06 PM 1/15/2008, you wrote:
> 
> >This is probably a classic issue..
> >
> >I have  5 buttons lined up next to each with no space between but 
> >they arent overlapping.
> >
> >I have rollover and rollout events.. but the rollout event doesnt 
> >work when i roll over to the next button..
> >
> >the onrollout event works only when i rollout on to negative 
> >space..which sucks
> >is there a workaround
> 
> _______________________________________________
> Flashcoders mailing list
> Flashcoders@chattyfig.figleaf.com
> http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

_________________________________________________________________
Share life as it happens with the new Windows Live.
http://www.windowslive.com/share.html?ocid=TXT_TAGHM_Wave2_sharelife_012008_______________________________________________
Flashcoders mailing list
Flashcoders@chattyfig.figleaf.com
http://chattyfig.figleaf.com/mailman/listinfo/flashcoders

Reply via email to