getWidthRatio method

double getWidthRatio(
  1. double val
)

Implementation

double getWidthRatio(double val) {
  if (screenWidth! >= 1200) {
    return val;
  }

  double res = (val / refWidth) * 100;
  double temp = res * blockSizeHorizontal;

  return temp;
}