remove page Offsets to fix probing in scrolled browser window
This commit is contained in:
parent
ef88fdeb90
commit
efddb36049
8
wires.js
8
wires.js
|
@ -335,15 +335,11 @@ function setChipStyle(props){
|
|||
|
||||
|
||||
function localx(el, gx){
|
||||
var lx = gx+window.pageXOffset;
|
||||
lx-=el.getBoundingClientRect().left
|
||||
return lx;
|
||||
return gx-el.getBoundingClientRect().left;
|
||||
}
|
||||
|
||||
function localy(el, gy){
|
||||
var ly = gy+window.pageYOffset;
|
||||
ly-=el.getBoundingClientRect().top
|
||||
return ly;
|
||||
return gy-el.getBoundingClientRect().top;
|
||||
}
|
||||
|
||||
function setStatus(){
|
||||
|
|
Loading…
Reference in New Issue