Rename Image.fromNetwork and Image.fromAssetBundle (#5149)

These now have sorter names to make the callers less verbose.
This commit is contained in:
Adam Barth
2016-07-29 13:28:08 -07:00
committed by GitHub
parent 79364f0a06
commit c674b4a803
14 changed files with 32 additions and 74 deletions

View File

@@ -427,7 +427,7 @@ class CardCollectionState extends State<CardCollection> {
if (_sunshine) {
cardCollection = new Stack(
children: <Widget>[
new Column(children: <Widget>[new Image.fromNetwork(src: _sunshineURL)]),
new Column(children: <Widget>[new Image.network(_sunshineURL)]),
new ShaderMask(child: cardCollection, shaderCallback: _createShader)
]
);

View File

@@ -157,8 +157,8 @@ class WeatherButton extends StatelessWidget {
child: new InkWell(
onTap: onPressed,
child: new Center(
child: new Image.fromAssetBundle(
name: icon,
child: new Image.asset(
icon,
width: _kWeatherIconSize,
height: _kWeatherIconSize
)