public int addMovingPoint(int x,int y){
  int position=addPoint(x,y);
  setMovingPoint((GrabPoint)polyGrabPoints.get(position));
  return position;
}

public int addMovingPoint ( int x , int y ) { int position = addPoint ( x , y ) ; setMovingPoint ( ( GrabPoint ) polyGrabPoints . get ( position ) ) ; return position ; }
add a point to the end of the polyline / polygon and then make it the moving one .
