countBottomSpace method

double countBottomSpace(
  1. int position
)

Implementation

double countBottomSpace(int position){
  if(position==keyArray.length-1||heightArray.length==0){
      return verticalSpace;
  }
  double bottom=0;
  for(int i=position;i<keyArray.length-1;i++){
     bottom=bottom+verticalSpace+(heightArray.length==0?0:heightArray[i+1]);
  }
  return (bottom)*animation.value+verticalSpace;
}