Merge 77570cff6db745cf4e8015a7eb97bb8c02cef87e into 06df71c51446e96939c6a615b7c34ce9123806ba

This commit is contained in:
Felipe Morschel 2026-02-19 14:16:17 -03:00 committed by GitHub
commit 1932b0de2a
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 3 deletions

View File

@ -747,14 +747,14 @@ Future<Codec> instantiateImageCodecWithSize(
FrameInfo? info;
try {
if (getTargetSize == null) {
return engine.renderer.instantiateImageCodec(buffer._list!);
return await engine.renderer.instantiateImageCodec(buffer._list!);
} else {
codec = await engine.renderer.instantiateImageCodec(buffer._list!);
info = await codec.getNextFrame();
final int width = info.image.width;
final int height = info.image.height;
final TargetImageSize targetSize = getTargetSize(width, height);
return engine.renderer.instantiateImageCodec(
return await engine.renderer.instantiateImageCodec(
buffer._list!,
targetWidth: targetSize.width,
targetHeight: targetSize.height,

View File

@ -364,7 +364,7 @@ Future<Uint8List> fetchImage(String url, ui_web.ImageCodecChunkCallback? chunkCa
}
if (chunkCallback != null && contentLength != null) {
return readChunked(response.payload, contentLength, chunkCallback);
return await readChunked(response.payload, contentLength, chunkCallback);
} else {
return await response.asUint8List();
}