
















1 看过FLASH帮助中的解释后,下面的语句便不难理解:
2 on (press) {
3 this.startDrag(false);//当鼠标在影片剪辑上按下时,开始拖拽。
4 }
5 on (release) {
6 this.stopDrag();//当鼠标释放时,停止对影片剪辑的拖拽。
7 }
8 ball.onMouseDown = function() {
9 //当鼠标按下时
10 if (this.hitTest(_xmouse, _ymouse, true)) {
11 this.startDrag(false);//如果影片剪辑与鼠标指针重叠时,开始拖拽
12 }
13 };
14 ball.onMouseUp = function() {
15 //当释放鼠标时 this.stopDrag();//停止对影片剪辑的拖拽。
16 };
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。