Fix crazy scrollbars all the time
This commit is contained in:
parent
7b9c106810
commit
3d660885e0
@ -115,8 +115,8 @@ function enableGuideBox(image, scalecorrectionfactor) {
|
||||
if (typeof scalecorrectionfactor == "undefined") {
|
||||
scalecorrectionfactor = 1;
|
||||
}
|
||||
// disable first to clear contents
|
||||
disableGuideBox();
|
||||
var context = $("#placementguidebox")[0].getContext('2d');
|
||||
context.clearRect(0, 0, $("#placementguidebox")[0].width, $("#placementguidebox")[0].height);
|
||||
$("#placementguidebox").css("display", "");
|
||||
// calculate size of guide image
|
||||
var pageWidthPx = $("#page-canvas-container .page-canvas")[0].getContext("2d").canvas.width;
|
||||
@ -161,4 +161,8 @@ function getMousePos(canvas, evt) {
|
||||
x: (evt.clientX - rect.left) * scaleX, // scale mouse coordinates after they have
|
||||
y: (evt.clientY - rect.top) * scaleY // been adjusted to be relative to element
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// Hide it at start
|
||||
// doesn't work in CSS because of reasons
|
||||
disableGuideBox();
|
Loading…
x
Reference in New Issue
Block a user