byWidth2<T> static method
T
byWidth2<T>(
- dynamic context,
- T size, [
- T? computerSmall2,
- T? computerSmall,
- T? largeTablet,
- T? tablet,
- T? phone,
- T? tiny,
Implementation
static T byWidth2<T>(context, T size,
[T? computerSmall2,
T? computerSmall,
T? largeTablet,
T? tablet,
T? phone,
T? tiny]) {
if (isComputerSmall2(context)) return computerSmall2 ?? size;
if (isComputerSmall(context)) return computerSmall ?? size;
if (isComputer(context)) return size;
if (isLargeTablet(context)) return largeTablet ?? size;
if (isTablet(context)) return tablet ?? size;
if (isPhone(context)) return phone ?? size;
if (isTinyLimit(context)) return tiny ?? size;
return size;
}