of static method
- BuildContext context
The closest instance of this class's data value that encloses the given context.
If there is no ancestor, it returns ThemeData.floatingActionButtonTheme. Applications can assume that the returned value will not be null.
Typical usage is as follows:
FloatingActionButtonThemeData theme = FloatingActionButtonTheme.of(context);
Implementation
static FloatingActionButtonThemeData of(BuildContext context) {
final FloatingActionButtonTheme? fabTheme = context
.dependOnInheritedWidgetOfExactType<FloatingActionButtonTheme>();
return fabTheme?.data ?? Theme.of(context).floatingActionButtonTheme;
}