setDimensions method

void setDimensions(
  1. double widthProvided,
  2. double heightProvided
)

Sets the screen dimensions.

Implementation

void setDimensions(
  double widthProvided,
  double heightProvided,
) {
  width = widthProvided;
  height = heightProvided;
  inch = sqrt((width * width) + (height * height));
}