resolveWith static method

WidgetStateColor resolveWith(
  1. WidgetPropertyResolver<Color> callback
)
override

Creates a WidgetStateColor from a WidgetPropertyResolver<Color> callback function.

If used as a regular color, the color resolved in the default state (the empty set of states) will be used.

The given callback parameter must return a non-null color in the default state.

Implementation

static WidgetStateColor resolveWith(WidgetPropertyResolver<Color> callback) => _WidgetStateColor(callback);