Use Image.toString instead of rolling our own each time

I meant to check this in as part of https://github.com/flutter/flutter/pull/1852
but forgot to commit the local change, d'oh.
This commit is contained in:
Ian Hickson 2016-02-13 17:54:10 -08:00
parent 3eb1b412e0
commit f54b8ad510
3 changed files with 3 additions and 9 deletions

View File

@ -251,10 +251,7 @@ class RenderImage extends RenderBox {
void debugDescribeSettings(List<String> settings) {
super.debugDescribeSettings(settings);
if (image != null)
settings.add('image: [${image.width}\u00D7${image.height}]');
else
settings.add('image: null');
settings.add('image: $image');
if (width != null)
settings.add('width: $width');
if (height != null)

View File

@ -11,7 +11,7 @@ class ImageInfo {
ImageInfo({ this.image, this.scale: 1.0 });
final ui.Image image;
final double scale;
String toString() => '[${image.width}\u00D7${image.height}] @ ${scale}x';
String toString() => '$image @ ${scale}x';
}
/// A callback for when the image is available.

View File

@ -1593,10 +1593,7 @@ class RawImage extends LeafRenderObjectWidget {
void debugFillDescription(List<String> description) {
super.debugFillDescription(description);
if (image != null)
description.add('image: [${image.width}\u00D7${image.height}]');
else
description.add('image: null');
description.add('image: $image');
if (width != null)
description.add('width: $width');
if (height != null)