Fixed clickDragger breaking on zoom-in.
This commit is contained in:
parent
de7dab5cab
commit
b27175bb7d
|
|
@ -531,9 +531,9 @@ class canopyUXUtils{
|
|||
//get difference between mouse and left edge of element
|
||||
var difference = event.clientX - this.element.getBoundingClientRect().left;
|
||||
}
|
||||
//check if we have a scrollbar because we're breaking shit
|
||||
var pageBreak = document.body.scrollWidth - document.body.getBoundingClientRect().width;
|
||||
|
||||
//check if we have a scrollbar because we're breaking shit, make sure to round actual width so we don't break when zoomed in
|
||||
var pageBreak = document.body.scrollWidth - Math.round(document.body.getBoundingClientRect().width);
|
||||
|
||||
//if we're not breaking the page, or we're moving left
|
||||
if((!this.breakingScreen && pageBreak <= 0) || event.clientX < this.handle.getBoundingClientRect().left){
|
||||
|
|
|
|||
Loading…
Reference in a new issue