开发者

AS2: rollover on attached movieclip

The following is the chunk of my code that is attaching开发者_如何转开发 a movieclip (from timeline), tracing thisDot works so it is not the variable which is a problem but there is no rollover applied to the attached movieclip.

    var dot_name:String = new String(Graphs[s]._name+"_dot"+i);
    var dotObj:Object = new Object();
    if (prevX != undefined) {
        dotObj._x = newX;
    } else {
        dotObj._x = 0;
    }
    dotObj._y = Slide_y;
    Graphs[s].chart.attachMovie("graph_dot",dot_name,Graphs[s].chart.getNextHighestDepth(),dotObj);
    eval(thisDot=Graphs[s]+".chart."+dot_name);
    Graphs_dots[s].push(thisDot);
    thisDot.onRollOver = function () {
        trace(this);


Looks to me that this row:

eval(thisDot=Graphs[s]+".chart."+dot_name);

should be this instead?

thisDot=eval(Graphs[s]+".chart."+dot_name);
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜