Skip to content

Instantly share code, notes, and snippets.

@ijoschek
Last active August 22, 2019 11:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ijoschek/b120de9348d59e20fa56d90567487e74 to your computer and use it in GitHub Desktop.
Save ijoschek/b120de9348d59e20fa56d90567487e74 to your computer and use it in GitHub Desktop.
flutter_gridview_tut
//...
class _MyHomePageState extends State<MyHomePage> {
_openImage(context, index) async {
showDialog(
context: context,
builder: (a) => AlertDialog(
title: Text("Look at this! Very Nice!"),
content: FadeInImage.memoryNetwork(
placeholder: kTransparentImage,
image: 'https://picsum.photos/id/$index/512'),
actions: <Widget>[
FlatButton(
onPressed: () {
_dismissDialog(context);
},
child: Text('Close'))
],
),
);
}
//...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment