标签:view nav timeout 开发 resize dev event and pre
//处理input focus时被键盘遮挡问题 inputFocus:function(){ if(/Android [4-6]/.test(navigator.appVersion)) { window.addEventListener("resize", function() { if(document.activeElement.tagName=="INPUT" || document.activeElement.tagName=="TEXTAREA") { window.setTimeout(function() { document.activeElement.scrollIntoViewIfNeeded(); },0); } }) } },
标签:view nav timeout 开发 resize dev event and pre
原文地址:http://www.cnblogs.com/gaofengming/p/6716624.html