From a09ffffacc18bfca1ec2b7f1730230bac2271bd3 Mon Sep 17 00:00:00 2001 From: Thibault Deckers Date: Sun, 3 Nov 2019 09:07:54 +0900 Subject: [PATCH] fixed section header icons mismatch on sort --- lib/widgets/album/thumbnail_collection.dart | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/widgets/album/thumbnail_collection.dart b/lib/widgets/album/thumbnail_collection.dart index f003ccea1..433996418 100644 --- a/lib/widgets/album/thumbnail_collection.dart +++ b/lib/widgets/album/thumbnail_collection.dart @@ -63,7 +63,9 @@ class ThumbnailCollectionContent extends StatelessWidget { if (appBar != null) appBar, ...sectionKeys.map((sectionKey) { Widget sliver = SectionSliver( - key: UniqueKey(), + // need key to prevent section header mismatch + // but it should not be unique key, otherwise sections are rebuilt when changing page + key: ValueKey(sectionKey), collection: collection, sections: _sections, sectionKey: sectionKey,