diff --git a/lib/ui/pages/profile/profileWallViewScreen.dart b/lib/ui/pages/profile/profileWallViewScreen.dart index 7d2f7ef5..689721b8 100644 --- a/lib/ui/pages/profile/profileWallViewScreen.dart +++ b/lib/ui/pages/profile/profileWallViewScreen.dart @@ -113,12 +113,14 @@ class _ProfileWallViewScreenState extends State thumb = widget.arguments![1].toString(); isLoading = true; updateViews(Provider.of(context, listen: false) - .profileWalls![index]["id"] + .profileWalls![index] + .data()["id"] .toString() .toUpperCase()); _futureView = getViews( Provider.of(context, listen: false) - .profileWalls![index]["id"] + .profileWalls![index] + .data()["id"] .toString() .toUpperCase()); _updatePaletteGenerator(); @@ -275,7 +277,8 @@ class _ProfileWallViewScreenState extends State Provider.of( context, listen: false) - .profileWalls![index]["id"] + .profileWalls![index] + .data()["id"] .toString() .toUpperCase(), style: Theme.of(context) @@ -375,7 +378,8 @@ class _ProfileWallViewScreenState extends State Provider.of( context, listen: false) - .profileWalls![index]["by"] + .profileWalls![index] + .data()["by"] .toString(), style: Theme.of(context) .textTheme @@ -401,7 +405,8 @@ class _ProfileWallViewScreenState extends State Provider.of( context, listen: false) - .profileWalls![index]["desc"] + .profileWalls![index] + .data()["desc"] .toString(), style: Theme.of(context) .textTheme @@ -427,7 +432,8 @@ class _ProfileWallViewScreenState extends State Provider.of( context, listen: false) - .profileWalls![index]["size"] + .profileWalls![index] + .data()["size"] .toString(), style: Theme.of(context) .textTheme @@ -451,7 +457,7 @@ class _ProfileWallViewScreenState extends State context, listen: false) .profileWalls![index] - ["resolution"] + .data()["resolution"] .toString(), style: Theme.of(context) .textTheme @@ -478,7 +484,7 @@ class _ProfileWallViewScreenState extends State context, listen: false) .profileWalls![index] - ["wallpaper_provider"] + .data()["wallpaper_provider"] .toString(), style: Theme.of(context) .textTheme @@ -514,7 +520,8 @@ class _ProfileWallViewScreenState extends State ? _imageFile.path : Provider.of(context, listen: false) - .profileWalls![index]["wallpaper_url"] + .profileWalls![index] + .data()["wallpaper_url"] .toString(), ), SetWallpaperButton( @@ -523,48 +530,56 @@ class _ProfileWallViewScreenState extends State ? _imageFile.path : Provider.of(context, listen: false) - .profileWalls![index]["wallpaper_url"] + .profileWalls![index] + .data()["wallpaper_url"] .toString(), ), FavouriteWallpaperButton( id: Provider.of(context, listen: false) - .profileWalls![index]["id"] + .profileWalls![index] + .data()["id"] .toString(), provider: Provider.of( context, listen: false) - .profileWalls![index]["wallpaper_provider"] + .profileWalls![index] + .data()["wallpaper_provider"] .toString(), prism: Provider.of(context, listen: false) - .profileWalls![index] as Map, + .profileWalls![index] + .data(), trash: false, ), ShareButton( id: Provider.of(context, listen: false) - .profileWalls![index]["id"] + .profileWalls![index] + .data()["id"] .toString(), provider: Provider.of( context, listen: false) .profileWalls![index] - ["wallpaper_provider"] + .data()["wallpaper_provider"] .toString(), url: Provider.of(context, listen: false) - .profileWalls![index]["wallpaper_url"] + .profileWalls![index] + .data()["wallpaper_url"] .toString(), thumbUrl: Provider.of( context, listen: false) - .profileWalls![index]["wallpaper_thumb"] + .profileWalls![index] + .data()["wallpaper_thumb"] .toString()), EditButton( url: Provider.of(context, listen: false) - .profileWalls![index]["wallpaper_url"] + .profileWalls![index] + .data()["wallpaper_url"] .toString(), ), ], @@ -605,7 +620,8 @@ class _ProfileWallViewScreenState extends State child: CachedNetworkImage( imageUrl: Provider.of(context, listen: false) - .profileWalls![index]["wallpaper_url"] + .profileWalls![index] + .data()["wallpaper_url"] .toString(), imageBuilder: (context, imageProvider) => Screenshot( controller: screenshotController, @@ -682,7 +698,8 @@ class _ProfileWallViewScreenState extends State onPressed: () { final link = Provider.of(context, listen: false) - .profileWalls![index]["wallpaper_url"]; + .profileWalls![index] + .data()["wallpaper_url"]; Navigator.push( context, PageRouteBuilder( diff --git a/lib/ui/widgets/profile/uploadedWallsGrid.dart b/lib/ui/widgets/profile/uploadedWallsGrid.dart index 550d60c5..254075c7 100644 --- a/lib/ui/widgets/profile/uploadedWallsGrid.dart +++ b/lib/ui/widgets/profile/uploadedWallsGrid.dart @@ -274,7 +274,7 @@ class _ProfileGridState extends State Provider.of( context) .profileWalls![index] - ["wallpaper_thumb"] + .data()["wallpaper_thumb"] .toString(), ), fit: BoxFit.cover)), @@ -302,10 +302,10 @@ class _ProfileGridState extends State arguments: [ index, Provider.of( - context, - listen: false) - .profileWalls![index] - ["wallpaper_thumb"], + context, + listen: false) + .profileWalls![index] + .data()["wallpaper_thumb"], ]); } },