of static method

DropdownMenuThemeData of(
  1. BuildContext context
)

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

If there is no enclosing DropdownMenuTheme widget, then ThemeData.dropdownMenuTheme is used.

Typical usage is as follows:

DropdownMenuThemeData theme = DropdownMenuTheme.of(context);

See also:

Implementation

static DropdownMenuThemeData of(BuildContext context) {
  return maybeOf(context) ?? Theme.of(context).dropdownMenuTheme;
}