init method
Initialize the Painter (e.g. Load Images)
Implementation
@override
void init() {
if (!_imagesLoaded && !_startedLoadingImages) {
_startedLoadingImages = true;
for (var i = 0; i < images.length; i++) {
final image = images[i];
loadImageFromAsset(image,
ext: jpegImages.contains(image) ? "jpg" : "png")
.then((result) => _imageMap[image] = result);
}
}
}