Merge pull request #168 from nanot1m/fix-square-selection
Square selection should work in all directions
This commit is contained in:
commit
be41bd0f1c
@ -1542,7 +1542,9 @@ class App extends React.Component<{}, AppState> {
|
|||||||
this.state.scrollY;
|
this.state.scrollY;
|
||||||
draggingElement.width = width;
|
draggingElement.width = width;
|
||||||
// Make a perfect square or circle when shift is enabled
|
// Make a perfect square or circle when shift is enabled
|
||||||
draggingElement.height = e.shiftKey ? width : height;
|
draggingElement.height = e.shiftKey
|
||||||
|
? Math.abs(width) * Math.sign(height)
|
||||||
|
: height;
|
||||||
|
|
||||||
generateDraw(draggingElement);
|
generateDraw(draggingElement);
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user