setImage method

void setImage(
  1. String image, {
  2. AutoImageTint? imageTint,
})

Updating the image which will be displayed on the leading edge of the list item cell.

Supports these formats:

  • Asset path: images/flutter_logo.png from pubspec.yaml assets
  • SVG asset: images/icon.svg rasterized to PNG before native display
  • File path: file:///path/to/image.png local file on device
  • Network URL: https://example.com/image.png remote image

Implementation

void setImage(String image, {AutoImageTint? imageTint}) {
  this.image = image;
  if (imageTint != null) this.imageTint = imageTint;
  FlutterCarPlayController.updateCPListItem(this);
}