1
0
mirror of https://github.com/beestat/app.git synced 2025-05-24 02:14:03 -04:00

Fixed toggling snapping breaking active dragging

This commit is contained in:
Jon Ziebell 2022-08-05 13:31:27 -04:00
parent 7ac646463f
commit db6cb0d1f4
3 changed files with 2 additions and 3 deletions

View File

@ -122,7 +122,6 @@ beestat.component.card.floor_plan_editor.prototype.decorate_drawing_pane_ = func
self.rerender(); self.rerender();
}); });
this.floor_plan_.addEventListener('clear_room', self.rerender.bind(this)); this.floor_plan_.addEventListener('clear_room', self.rerender.bind(this));
this.floor_plan_.addEventListener('toggle_snapping', self.rerender.bind(this));
this.floor_plan_.addEventListener('change_group', self.rerender.bind(this)); this.floor_plan_.addEventListener('change_group', self.rerender.bind(this));
// Add all of the entities to the SVG. // Add all of the entities to the SVG.

View File

@ -556,7 +556,7 @@ beestat.component.floor_plan.prototype.update_infobox = function() {
*/ */
beestat.component.floor_plan.prototype.toggle_snapping_ = function() { beestat.component.floor_plan.prototype.toggle_snapping_ = function() {
this.state_.snapping = !this.state_.snapping; this.state_.snapping = !this.state_.snapping;
this.dispatchEvent('toggle_snapping'); this.update_toolbar();
}; };
/** /**

View File

@ -179,7 +179,7 @@ beestat.component.floor_plan_entity.point.prototype.after_mousedown_handler_ = f
}; };
/** /**
* point dragging a point around. Snaps to X and Y of other points. * Handle dragging a point around. Snaps to X and Y of other points.
* *
* @param {Event} e * @param {Event} e
*/ */