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:
@@ -12,6 +12,8 @@ class FillTool extends Tool {
|
||||
return;
|
||||
this.fill(mousePos);
|
||||
currentLayer.updateLayerPreview();
|
||||
|
||||
new HistoryState().EditCanvas();
|
||||
}
|
||||
|
||||
|
||||
@@ -37,9 +39,6 @@ class FillTool extends Tool {
|
||||
return (r == color[0] && g == color[1] && b == color[2] && a == color[3]);
|
||||
}
|
||||
|
||||
//save history state
|
||||
new HistoryState().EditCanvas();
|
||||
|
||||
//temporary image holds the data while we change it
|
||||
let tempImage = currentLayer.context.getImageData(0, 0, canvasSize[0], canvasSize[1]);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user