Music mode controls layout improvements

This commit is contained in:
Arkadiusz Fal 2022-08-29 17:57:43 +02:00
parent a2b9d4d938
commit 3a05462965

View File

@ -609,6 +609,7 @@ final class PlayerModel: ObservableObject {
} }
func closeCurrentItem(finished: Bool = false) { func closeCurrentItem(finished: Bool = false) {
controls.hide()
pause() pause()
closePiP() closePiP()
@ -960,12 +961,16 @@ final class PlayerModel: ObservableObject {
musicMode.toggle() musicMode.toggle()
if musicMode { if musicMode {
aspectRatio = VideoPlayerView.defaultAspectRatio
controls.presentingControls = true controls.presentingControls = true
controls.removeTimer() controls.removeTimer()
backend.startMusicMode() backend.startMusicMode()
} else { } else {
backend.stopMusicMode() backend.stopMusicMode()
Delay.by(0.25) {
self.updateAspectRatio()
}
controls.resetTimer() controls.resetTimer()
} }