AdaptiveHelpers extension
- on
Properties
- mediaQuery → MediaQueryData
-
The MediaQueryData from the closest instance of this class that encloses the given context.
no setter
- screenHeight → double
-
The vertical extent of the screen size.
no setter
- screenIsLandscape → bool
-
Whether the device is in landscape mode.
no setter
- screenIsPortrait → bool
-
Whether the device is in portrait mode.
no setter
- screenWidth → double
-
The horizontal extent of the screen size.
no setter
Methods
-
byFormFactor<
T> ({required T onMobile, required T onTablet, required T onDesktop, bool followDeviceOrientation = true}) → T - Returns either onMobile, onTablet or onDesktop depending on the current formFactor.
-
formFactor(
{bool followDeviceOrientation = true}) → FormFactor - Returns the correct FormFactor based on the ScreenWidthBreakpoints.