mirror of
https://github.com/bytedance/xgplayer.git
synced 2025-04-05 11:18:46 +08:00
fix(xgplayer): 修复全屏退出后恢复页面滚动不生效的问题
This commit is contained in:
parent
67194eec64
commit
92db2fc65a
@ -1803,7 +1803,7 @@ class Player extends MediaProxy {
|
|||||||
const { _fullScreenOffset, config } = this
|
const { _fullScreenOffset, config } = this
|
||||||
if (config.needFullscreenScroll) {
|
if (config.needFullscreenScroll) {
|
||||||
// 保证页面scroll的情况下退出全屏 页面回到原位置
|
// 保证页面scroll的情况下退出全屏 页面回到原位置
|
||||||
window.scrollTo(_fullScreenOffset.left, _fullScreenOffset.top)
|
document.documentElement.scrollTo(_fullScreenOffset.left, _fullScreenOffset.top)
|
||||||
Util.setTimeout( this, () => {
|
Util.setTimeout( this, () => {
|
||||||
this.fullscreen = false
|
this.fullscreen = false
|
||||||
this._fullScreenOffset = null
|
this._fullScreenOffset = null
|
||||||
|
Loading…
x
Reference in New Issue
Block a user