private Point calculateItemPositions(){
  final Point center=getActionViewCenter();
  RectF area=new RectF(center.x - radius,center.y - radius,center.x + radius,center.y + radius);
  Path orbit=new Path();
  orbit.addArc(area,startAngle,endAngle - startAngle);
  PathMeasure measure=new PathMeasure(orbit,false);
  int divisor;
  if (Math.abs(endAngle - startAngle) >= 360 || subActionItems.size() <= 1) {
    divisor=subActionItems.size();
  }
 else {
    divisor=subActionItems.size() - 1;
  }
  for (int i=0; i < subActionItems.size(); i++) {
    float[] coords=new float[]{0f,0f};
    measure.getPosTan((i) * measure.getLength() / divisor,coords,null);
    subActionItems.get(i).x=(int)coords[0] - subActionItems.get(i).width / 2;
    subActionItems.get(i).y=(int)coords[1] - subActionItems.get(i).height / 2;
  }
  return center;
}

private Point calculateItemPositions ( ) { final Point center = getActionViewCenter ( ) ; RectF area = new RectF ( center . x - radius , center . y - radius , center . x + radius , center . y + radius ) ; Path orbit = new Path ( ) ; orbit . addArc ( area , startAngle , endAngle - startAngle ) ; PathMeasure measure = new PathMeasure ( orbit , false ) ; int divisor ; if ( Math . abs ( endAngle - startAngle ) >= 360 || subActionItems . size ( ) <= 1 ) { divisor = subActionItems . size ( ) ; } else { divisor = subActionItems . size ( ) - 1 ; } for ( int i = 0 ; i < subActionItems . size ( ) ; i ++ ) { float [ ] coords = new float [ ] { 0f , 0f } ; measure . getPosTan ( ( i ) * measure . getLength ( ) / divisor , coords , null ) ; subActionItems . get ( i ) . x = ( int ) coords [ 0 ] - subActionItems . get ( i ) . width / 2 ; subActionItems . get ( i ) . y = ( int ) coords [ 1 ] - subActionItems . get ( i ) . height / 2 ; } return center ; }
calculates the desired positions of all items .
