Skip to content

Commit

Permalink
fix: UI issue with top margin on content page (#341)
Browse files Browse the repository at this point in the history
[iOS] UI issue with top margin on content page on iPad #335
  • Loading branch information
forgotvas authored Mar 21, 2024
1 parent cf0b855 commit 75bba40
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions Course/Course/Presentation/Video/EncodedVideoPlayer.swift
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ public struct EncodedVideoPlayer: View {
}, seconds: { seconds in
currentTime = seconds
})
.statusBarHidden(false)
.aspectRatio(16 / 9, contentMode: .fit)
.frame(minWidth: isHorizontal ? reader.size.width * 0.6 : 380)
.cornerRadius(12)
Expand Down Expand Up @@ -125,10 +124,14 @@ public struct EncodedVideoPlayer: View {
}
}
}
}.padding(.horizontal, isHorizontal ? 0 : 8)
.onDisappear {
viewModel.controller.player?.allowsExternalPlayback = false
}
}
.padding(.horizontal, isHorizontal ? 0 : 8)
.onDisappear {
viewModel.controller.player?.allowsExternalPlayback = false
}
.onAppear {
viewModel.controller.setNeedsStatusBarAppearanceUpdate()
}
}

private func pauseScrolling() {
Expand Down

0 comments on commit 75bba40

Please sign in to comment.