datagrid3

value = sx+sw*Math.SQRT2*Math.sin((ag-45)*Math.PI/180);
value = sx+sw*Math.SQRT2*Math.sin((ag-135)*Math.PI/180);
private function _do_r1(e:MouseEvent):void{
r1.angleFrom=r1.angleTo;
if (r1.angleFrom>=360) r1.angleFrom-=360;
r1.angleTo=r1.angleTo+90;
if (r1.angleTo >360) r1.angleTo=r1.angleTo-360;
r1.target = can1;
r1.stop();
r1.addEventListener(EffectEvent.EFFECT_END,_do_r1end);
r1.play();

r2.target=bt1;
r2.angleFrom=r1.angleFrom;
r2.angleTo=360-r1.angleTo;
r2.stop();
r2.play();
r3.target=bt2;
r3.angleFrom=r1.angleFrom;
r3.angleTo=360-r1.angleTo;
r3.stop();
r3.play();


}

private function _do_r1end(e:EffectEvent):void{
can1.x = getrx(270,170*sv.value,r1.angleTo);
can1.y = getry(270,170*sv.value,r1.angleTo);

}
private function _do_resize(e:MouseEvent):void{
rz1.target=can1;
rz1.widthBy=-can1.width/10;
rz1.heightBy=-can1.height/10;
can1.x = getrx(270,170*(can1.width*0.9/340),r1.angleTo);
can1.y = getry(270,170*(can1.width*0.9/340),r1.angleTo);

// rz1.widthFrom = can1.width;
// rz1.widthTo = can1.width/2;
// rz1.heightFrom=can1.height;
// rz1.heightTo = can1.height/2;
rz1.stop();
rz1.play();
}
private function _do_show():void{
can1.x = getrx(270,170*sv.value,r1.angleTo);
can1.y = getry(270,170*sv.value,r1.angleTo);

var i:int = 2;
// Alert.show(sv.value.toString()+"dg"+dataGrid.width.toString()+"h:"+dataGrid.height.toString()+"can1"+can1.width.toString()
// + "ch:" + can1.height.toString());
// Alert.show(Math.sin(45*Math.PI/180).toString());
//Alert.show(r1.angleTo.toString() + can1.x.toString()+ can1.y.toString());
// Alert.show("from"+r1.angleFrom.toString() + "to" + r1.angleTo.toString());

}

你可能感兴趣的:(360)