var LY = {
//封装可视窗口的宽高
getViewportOffset : function(){
if(window.innerWidth){
return {
w : window.innerWidth,
h : window.innerHeight
}
}else{
if(document.compatMode == "BackCompat"){
return {
w : document.body.clientWidth,
h : document.body.clientHeight,
}
}else{
return {
w : document.documentElement.clientWidth,
h : document.documentElement.clientHeight
}
}
}
//封装可视窗口的宽高
getViewportOffset : function(){
if(window.innerWidth){
return {
w : window.innerWidth,
h : window.innerHeight
}
}else{
if(document.compatMode == "BackCompat"){
return {
w : document.body.clientWidth,
h : document.body.clientHeight,
}
}else{
return {
w : document.documentElement.clientWidth,
h : document.documentElement.clientHeight
}
}
}
},
}