Commit c2d9bd4a authored by Nature's avatar Nature

键盘监听函数

parent d761bdc5
......@@ -163,6 +163,15 @@
}, false)
layer.onclick = null
}
//初始化键盘监听方式
window.addEventListener('native.keyboardhide', function (e) {
if(scollFlag){
scollFlag=false
clickElement.fastClickScrollParent.style.paddingBottom = '0px'
clickElement.fastClickScrollParent.style.transform = "translate(0px, 0px) scale(1) translateZ(0px)"
}
})
}
/**
......@@ -815,20 +824,6 @@
return false
}
window.addEventListener('native.keyboardhide', function (e) {
if(scollFlag){
scollFlag=false
// clickElement.fastClickScrollParent.style.paddingBottom = contentPaddingBottom + 'px'
// clickElement.fastClickScrollParent.scrollTop =scrollTop
targetElement.fastClickScrollParent.style.paddingBottom = '0px'
/*clickElement.fastClickScrollParent.style.webkitTransform = "translate(0px, 0px) scale(1) translateZ(0px)"
clickElement.fastClickScrollParent.style.MozTransform = "translate(0px, 0px) scale(1) translateZ(0px)"
clickElement.fastClickScrollParent.style.msTransform = "translate(0px, 0px) scale(1) translateZ(0px)"
clickElement.fastClickScrollParent.style.OTransform = "translate(0px, 0px) scale(1) translateZ(0px)"*/
clickElement.fastClickScrollParent.style.transform = "translate(0px, 0px) scale(1) translateZ(0px)"
}
})
function scollContent (pointY,targetElement) {
innerHeight = window.innerHeight
var keyBoardHeight = getKeyBoardHeight()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment