Cmd-A to select everything (#51)
This commit is contained in:
parent
278fc11d22
commit
3b919f3235
@ -381,6 +381,7 @@ class App extends React.Component<{}, AppState> {
|
|||||||
if (event.key === "Escape") {
|
if (event.key === "Escape") {
|
||||||
clearSelection();
|
clearSelection();
|
||||||
drawScene();
|
drawScene();
|
||||||
|
event.preventDefault();
|
||||||
} else if (event.key === "Backspace") {
|
} else if (event.key === "Backspace") {
|
||||||
deleteSelectedElements();
|
deleteSelectedElements();
|
||||||
drawScene();
|
drawScene();
|
||||||
@ -402,6 +403,12 @@ class App extends React.Component<{}, AppState> {
|
|||||||
});
|
});
|
||||||
drawScene();
|
drawScene();
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
|
} else if (event.key === "a" && event.metaKey) {
|
||||||
|
elements.forEach(element => {
|
||||||
|
element.isSelected = true;
|
||||||
|
});
|
||||||
|
drawScene();
|
||||||
|
event.preventDefault();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user