From 0b5b38c8b44c0e2411e3cf5b8b2f7045328253e1 Mon Sep 17 00:00:00 2001 From: Dan Field Date: Tue, 16 Jun 2020 15:14:04 -0700 Subject: [PATCH] Instantiate image codec doc fix (flutter/engine#19062) Correctly describe the way aspect ratio is managed when one parameter is not specified. --- engine/src/flutter/lib/ui/painting.dart | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/engine/src/flutter/lib/ui/painting.dart b/engine/src/flutter/lib/ui/painting.dart index 32f7c7e6a7..b78f9b4761 100644 --- a/engine/src/flutter/lib/ui/painting.dart +++ b/engine/src/flutter/lib/ui/painting.dart @@ -1704,8 +1704,9 @@ class Codec extends NativeFieldWrapperClass2 { /// The [targetWidth] and [targetHeight] arguments specify the size of the output /// image, in image pixels. If they are not equal to the intrinsic dimensions of the /// image, then the image will be scaled after being decoded. If only one dimension -/// is specified, the omitted dimension will remain its original size. If both are -/// not specified, then the image maintains its real size. +/// is specified, the omitted dimension will be scaled to maintain the original +/// aspect ratio. If both are not specified, then the image maintains its real +/// size. /// /// The returned future can complete with an error if the image decoding has /// failed.