Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

滚动过程中是否可以不暂停画中画的视频播放 #526

Closed
hstdt opened this issue May 20, 2022 · 2 comments
Closed

滚动过程中是否可以不暂停画中画的视频播放 #526

hstdt opened this issue May 20, 2022 · 2 comments
Labels

Comments

@hstdt
Copy link

hstdt commented May 20, 2022

你的新功能建议是否牵扯到某个常见的问题?
滚动时暂停播放视频

你希望达到的效果
希望在滚动过程中可以不要暂停画中画的视频播放

你能考虑到的可选实现方案

目前手动控制了一下,但是是否可以做成默认实现。以及不确定逻辑是否有问题。

if #available(iOS 14.0, *) {
    player.playbackObserver.pictureInPictureStatusDidChangeExeBlock = { player in
        let status: [SJPictureInPictureStatus] = [.running, .starting]
        if status.contains(player.playbackController.pictureInPictureStatus) {
            player.pauseWhenScrollDisappeared = false
        } else {
            player.pauseWhenScrollDisappeared = true
        }
    }
}
@hstdt hstdt added the feature label May 20, 2022
@hstdt hstdt changed the title 画中画模式播放的时候,即使isAppearedInTheScrollingView为true,还是不要进行暂停吧 画中画模式播放的时候是否可以不要暂停画中画的视频播放 May 20, 2022
@hstdt hstdt changed the title 画中画模式播放的时候是否可以不要暂停画中画的视频播放 滚动过程中是否可以不暂停画中画的视频播放 May 20, 2022
@changsanjiang
Copy link
Owner

收到, 后续版本完善一下

@changsanjiang
Copy link
Owner

已在新版完善 SJBaseVideoPlayer v3.7.3

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants