1
0
mirror of https://github.com/yattee/yattee.git synced 2024-12-14 22:30:32 +05:30

Fix toggling player view

This commit is contained in:
Arkadiusz Fal 2022-06-26 17:23:56 +02:00
parent 616886f0d2
commit e69a329813
2 changed files with 17 additions and 10 deletions

View File

@ -165,7 +165,9 @@ final class PlayerModel: ObservableObject {
}
#endif
presentingPlayer = true
DispatchQueue.main.async { [weak self] in
self?.presentingPlayer = true
}
#if os(macOS)
Windows.player.open()
@ -174,8 +176,10 @@ final class PlayerModel: ObservableObject {
}
func hide() {
playingFullScreen = false
presentingPlayer = false
DispatchQueue.main.async { [weak self] in
self?.playingFullScreen = false
self?.presentingPlayer = false
}
#if os(iOS)
if Defaults[.lockPortraitWhenBrowsing] {

View File

@ -49,13 +49,16 @@ struct AppSidebarNavigation: View {
.frame(minWidth: sidebarMinWidth)
VStack {
HStack(alignment: .center) {
Spacer()
Image(systemName: "4k.tv")
.renderingMode(.original)
.font(.system(size: 60))
.foregroundColor(.accentColor)
Spacer()
BrowserPlayerControls {
HStack(alignment: .center) {
Spacer()
Image(systemName: "4k.tv")
.renderingMode(.original)
.font(.system(size: 60))
.foregroundColor(.accentColor)
Spacer()
}
.frame(maxHeight: .infinity)
}
}
}