Skip to content

Commit

Permalink
Fix Add tag dialog not showing
Browse files Browse the repository at this point in the history
  • Loading branch information
Hamza417 committed Sep 19, 2024
1 parent 2618658 commit 4967c08
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -503,7 +503,8 @@ fun SelectionMenu(modifier: Modifier = Modifier,
fun WallpaperMenu(setShowDialog: (Boolean) -> Unit,
wallpaper: Wallpaper,
onDelete: (Wallpaper) -> Unit,
onSelect: () -> Unit = {}) {
onSelect: () -> Unit = {},
onAddTag: () -> Unit = {}) {

val context = LocalContext.current
val coroutineScope = rememberCoroutineScope()
Expand Down Expand Up @@ -616,7 +617,6 @@ fun WallpaperMenu(setShowDialog: (Boolean) -> Unit,
Button(
onClick = {
showTagDialog.value = true
setShowDialog(false)
},
colors = ButtonDefaults.buttonColors(
containerColor = Color.White,
Expand Down
4 changes: 2 additions & 2 deletions app/src/main/java/app/simple/peri/compose/nav/Navigation.kt
Original file line number Diff line number Diff line change
Expand Up @@ -16,14 +16,14 @@ import androidx.navigation.compose.NavHost
import androidx.navigation.compose.composable
import androidx.navigation.compose.rememberNavController
import app.simple.peri.compose.screens.AutoWallpaper
import app.simple.peri.compose.screens.FolderList
import app.simple.peri.compose.screens.Folders
import app.simple.peri.compose.screens.Home
import app.simple.peri.compose.screens.Settings
import app.simple.peri.compose.screens.Setup
import app.simple.peri.compose.screens.TaggedWallpapers
import app.simple.peri.compose.screens.Tags
import app.simple.peri.compose.screens.Wallpaper
import app.simple.peri.compose.screens.WallpaperList
import app.simple.peri.compose.screens.isSetupComplete
import app.simple.peri.utils.ConditionUtils.invert

Expand All @@ -50,7 +50,7 @@ fun PeristyleNavigation(context: Context) {
}

composableWithTransitions(Routes.WALLPAPERS_LIST) {
FolderList(navController)
WallpaperList(navController)
}

composableWithTransitions(Routes.SETTINGS) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import app.simple.peri.models.Wallpaper
import app.simple.peri.viewmodels.FolderDataViewModel

@Composable
fun FolderList(navController: NavController? = null) {
fun WallpaperList(navController: NavController? = null) {
val folder = navController?.previousBackStackEntry?.savedStateHandle?.get<Folder>(Routes.FOLDER_ARG)

// Ensure folder is not null before proceeding
Expand Down

0 comments on commit 4967c08

Please sign in to comment.