mirror of
https://github.com/immich-app/immich.git
synced 2025-04-21 07:26:25 +02:00
fix(mobile): deletion of single assets (#15597)
fix: set asset in currentassetprovider on image load Co-authored-by: Alex <alex.tran1502@gmail.com>
This commit is contained in:
parent
c0210bd6c0
commit
3c1fa22109
1 changed files with 5 additions and 0 deletions
|
@ -262,6 +262,11 @@ class GalleryViewerPage extends HookConsumerWidget {
|
|||
|
||||
PhotoViewGalleryPageOptions buildAsset(BuildContext context, int index) {
|
||||
var newAsset = loadAsset(index);
|
||||
|
||||
WidgetsBinding.instance.addPostFrameCallback((_) {
|
||||
ref.read(currentAssetProvider.notifier).set(newAsset);
|
||||
});
|
||||
|
||||
final stackId = newAsset.stackId;
|
||||
if (stackId != null && currentIndex.value == index) {
|
||||
final stackElements =
|
||||
|
|
Loading…
Add table
Reference in a new issue