setTheme method

void setTheme(
  1. ThemeData value
)

Implementation

void setTheme(ThemeData value) {
  if (config.darkTheme == null) {
    config = config.copyWith(theme: value);
  } else {
    if (value.brightness == Brightness.light) {
      config = config.copyWith(theme: value);
    } else {
      config = config.copyWith(darkTheme: value);
    }
  }
  update();
}