removed "public" modifier for getMaxWidth and getMaxHeight methods