of static method

ActionIconThemeData? of(
  1. BuildContext context
)

The closest instance of this class that encloses the given context.

If there is no enclosing ActionIconTheme widget, then ThemeData.actionIconTheme is used.

Typical usage is as follows:

ActionIconThemeData? theme = ActionIconTheme.of(context);

Implementation

static ActionIconThemeData? of(BuildContext context) {
  final ActionIconTheme? actionIconTheme = context.dependOnInheritedWidgetOfExactType<ActionIconTheme>();
  return actionIconTheme?.data ?? Theme.of(context).actionIconTheme;
}