Skip to content

Commit

Permalink
Fix "Metrics overlay" setting on mobile
Browse files Browse the repository at this point in the history
  • Loading branch information
MGaetan89 committed Jul 30, 2024
1 parent 2550341 commit d66cce9
Showing 1 changed file with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,14 @@ fun PlaybackSettingsContent(player: Player) {
SettingsHome(
settings = settings,
settingsClicked = {
navController.navigate(it.destination.route) {
launchSingleTop = true
val destination = it.destination

if (destination is SettingsRoutes.MetricsOverlay) {
settingsViewModel.setMetricsOverlayEnabled(!destination.enabled)
} else {
navController.navigate(destination.route) {
launchSingleTop = true
}
}
},
)
Expand Down

0 comments on commit d66cce9

Please sign in to comment.