
在java的applet界面中用鼠标点击拖动画出矩形的代码是怎么编译?
1个回答
展开全部
point firstPoint;
point secondPoint;
onpress(){save the first point}
onrelease(){
if(secondPoint not equals firstPoint){
drawShape(firstPoint, secondPoint);
}
}
point secondPoint;
onpress(){save the first point}
onrelease(){
if(secondPoint not equals firstPoint){
drawShape(firstPoint, secondPoint);
}
}
推荐律师服务:
若未解决您的问题,请您详细描述您的问题,通过百度律临进行免费专业咨询