Fix handle drag alignment

master
William Toohey 10 years ago
parent 42e18c8394
commit b6ba39f727
  1. 5
      src/js/HuesEditor.js

@ -519,10 +519,11 @@ HuesEditor.prototype.uiCreateEditArea = function() {
handleContainer.addEventListener("mousedown", (e) => {
e.preventDefault();
var editTop = this.editArea.getBoundingClientRect().top;
var handleSize = this.resizeHandle.clientHeight;
var resizer = (e) => {
var editTop = this.editArea.getBoundingClientRect().top;
this.buildEditSize = Math.floor(e.clientY - editTop);
this.buildEditSize = Math.floor(e.clientY - editTop + handleSize/2);
this.resize();
};

Loading…
Cancel
Save