as3.0 切换剪辑的层setChildIndex

for (var i:int=1; i<=3; i++)
{
 this["bt" + i].buttonMode = true;
 this["bt" + i].mouseChildren = false;
 this["bt" + i].addEventListener(MouseEvent.CLICK,clickHandler);
}
function clickHandler(e:MouseEvent)
{

 e.currentTarget.parent.setChildIndex(e.currentTarget,(e.currentTarget.parent.numChildren-1));
}

 

你可能感兴趣的:(function,职场,休闲)