Add disk cache

This commit is contained in:
Christian Pauly
2020-04-10 18:00:45 +02:00
parent e41f1e30e8
commit daa739ed35
3 changed files with 19 additions and 6 deletions

View File

@ -40,7 +40,10 @@ class Avatar extends StatelessWidget {
child: CircleAvatar(
radius: size / 2,
backgroundImage: mxContent.mxc?.isNotEmpty ?? false
? AdvancedNetworkImage(src)
? AdvancedNetworkImage(
src,
useDiskCache: true,
)
: null,
backgroundColor: mxContent.mxc.isEmpty
? name?.color ?? Theme.of(context).secondaryHeaderColor