Merge pull request #117 from paulkaplan/also-ctrl-key

Allow ctrl key to zoom
This commit is contained in:
DD Liu 2017-10-27 11:20:10 -04:00 committed by GitHub
commit 2be90c1633

View file

@ -125,7 +125,7 @@ class PaperCanvas extends React.Component {
}
}
handleWheel (event) {
if (event.metaKey) {
if (event.metaKey || event.ctrlKey) {
// Zoom keeping mouse location fixed
const canvasRect = this.canvas.getBoundingClientRect();
const offsetX = event.clientX - canvasRect.left;