Refactor: Make FullScreenDialog dismissible

This commit introduces a dismiss functionality to the `FullScreenDialog`.

The `FullScreenDialog` now accepts an `onDismiss` lambda parameter.
This `onDismiss` lambda is invoked when a dismiss request is made for the dialog.

In `PhotoViewScreen`, the `onDismiss` lambda passed to `FullScreenDialog` is now the `onDismiss` lambda received by the `PhotoViewScreen` itself.
This commit is contained in:
2025-08-19 23:15:37 +03:00
parent 22e8a5c09e
commit 600aed40e7
2 changed files with 9 additions and 5 deletions
@@ -80,7 +80,10 @@ fun PhotoViewDialog(
val applicationContext = LocalContext.current.applicationContext
if (photoViewerInfo != null) {
FullScreenDialog(modifier = modifier) {
FullScreenDialog(
modifier = modifier,
onDismiss = onDismiss
) {
val viewModel = remember(true) {
PhotoViewViewModelImpl(
arguments = PhotoViewArguments(