移动 chrome 在滚动时触发调整大小事件 [英] mobile chrome fires resize event on scroll

查看:20
本文介绍了移动 chrome 在滚动时触发调整大小事件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在 Galaxy s4、android 4.2.2 上使用 chrome 移动浏览器,出于某种原因,每次我向下滚动页面时,它都会触发一个调整大小事件,该事件通过 jquery.cycle2 幻灯片中的图像缩放进行验证.

I'm using the chrome mobile browser on galaxy s4, android 4.2.2 and for some reason every time I scroll the page down, it fires a resize event verified by the scaling of images from a jquery.cycle2 slideshow.

知道为什么会发生这种情况吗?

Any idea why this might be happening?

推荐答案

出于好奇,我试图重现它,如果我是正确的,这是由导航铬栏引起的.

Just for curiosity, I was trying to reproduce it and if I'm correct this is caused by the navigation chrome bar.

当您向下滚动并且 chrome 隐藏浏览器导航栏时,它会调整窗口大小,但这是正确的,因为之后由于浏览器导航栏留下的可用空间,我们有更大的窗口大小.

When you scroll down and chrome hides the browser navigation bar it produces a window resize, but this is correct, because after that we have a bigger window size due to the free space that the browser nav bar has left.

相关文章:https://developers.google.com/web/updates/2016/12/url-bar-resizing

考虑CWitty 回答以避免这种行为.

这篇关于移动 chrome 在滚动时触发调整大小事件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆