loadBackgroundDecoration method

BoxDecoration loadBackgroundDecoration()

Implementation

BoxDecoration loadBackgroundDecoration() {
  if (option.backgroundImage != null) {
    return BoxDecoration(
      image: DecorationImage(
        image: option.backgroundImage!.image,
        fit: BoxFit.cover,
        colorFilter: new ColorFilter.mode(
            Colors.black.withOpacity(0.4), BlendMode.dstATop),
        alignment: backgroundDecorationAlignment,
      ),
      color: option.backgroundColor,
    );
  } else {
    return BoxDecoration(
      color: option.backgroundColor,
    );
  }
}