Lines Matching refs:coords

462 this.getClientOffset=function(elt){var addOffset=function addOffset(elt,coords,view){var p=elt.offs…  argument
464 if(elt.offsetLeft){coords.x+=elt.offsetLeft+chrome.getMeasurementInPixels(elt,"borderLeft")
465 }if(elt.offsetTop){coords.y+=elt.offsetTop+chrome.getMeasurementInPixels(elt,"borderTop")
466 }if(p){if(p.nodeType==1){addOffset(p,coords,view)
468 if(!otherView.opener&&otherView.frameElement){addOffset(otherView.frameElement,coords,otherView)
471 var coords={x:0,y:0}; class in getClientOffset
473 addOffset(elt,coords,view)
474 }return coords
476 this.getViewOffset=function(elt,singleFrame){function addOffset(elt,coords,view){var p=elt.offsetPa… argument
477 coords.x+=elt.offsetLeft-(p?p.scrollLeft:0);
478 coords.y+=elt.offsetTop-(p?p.scrollTop:0);
480 if(parentStyle.position!="static"){coords.x+=parseInt(parentStyle.borderLeftWidth);
481 coords.y+=parseInt(parentStyle.borderTopWidth);
482 if(p.localName=="TABLE"){coords.x+=parseInt(parentStyle.paddingLeft);
483 coords.y+=parseInt(parentStyle.paddingTop)
485 coords.x+=parseInt(style.marginLeft);
486 coords.y+=parseInt(style.marginTop)
487 }}}else{if(p.localName=="BODY"){coords.x+=parseInt(parentStyle.borderLeftWidth);
488 coords.y+=parseInt(parentStyle.borderTopWidth)
490 while(p!=parent){coords.x-=parent.scrollLeft;
491 coords.y-=parent.scrollTop;
493 }addOffset(p,coords,view)
495 coords.x+=parseInt(style.borderLeftWidth);
496 coords.y+=parseInt(style.borderTopWidth);
498 coords.x-=parseInt(htmlStyle.paddingLeft);
499 coords.y-=parseInt(htmlStyle.paddingTop)
500 }if(elt.scrollLeft){coords.x+=elt.scrollLeft
501 }if(elt.scrollTop){coords.y+=elt.scrollTop
503 if(win&&(!singleFrame&&win.frameElement)){addOffset(win.frameElement,coords,win)
504 }}}var coords={x:0,y:0}; class in getViewOffset
505 if(elt){addOffset(elt,coords,elt.ownerDocument.defaultView)
506 }return coords