mirror of
https://github.com/lospec/pixel-editor.git
synced 2023-08-10 21:12:51 +03:00
Added back tool shortctus
Made Events an IIFE instead of a class, fixed a bug in the selection tool.
This commit is contained in:
@@ -1,3 +1,5 @@
|
||||
// TODO: FIX SELECTION
|
||||
|
||||
class RectangleTool extends ResizableTool {
|
||||
// Saving the empty rect svg
|
||||
emptyRectangleSVG = document.getElementById("rectangle-empty-button-svg");
|
||||
@@ -41,6 +43,8 @@ class RectangleTool extends ResizableTool {
|
||||
|
||||
this.startMousePos[0] = Math.floor(mousePos[0] / zoom) + 0.5;
|
||||
this.startMousePos[1] = Math.floor(mousePos[1] / zoom) + 0.5;
|
||||
|
||||
new HistoryState().EditCanvas();
|
||||
}
|
||||
|
||||
onDrag(mousePos, cursorTarget) {
|
||||
|
||||
Reference in New Issue
Block a user