Skip to content

Commit

Permalink
Merge pull request #15268 from light-and-ray/handle_0_wheel_deltaX
Browse files Browse the repository at this point in the history
handle 0 wheel deltaY
  • Loading branch information
AUTOMATIC1111 committed Mar 16, 2024
2 parents bb9df5c + c364b60 commit 874809e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion extensions-builtin/canvas-zoom-and-pan/javascript/zoom.js
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@ onUiLoaded(async() => {

targetElement.addEventListener("wheel", e => {
// change zoom level
const operation = e.deltaY > 0 ? "-" : "+";
const operation = (e.deltaY || -e.wheelDelta) > 0 ? "-" : "+";
changeZoomLevel(operation, e);

// Handle brush size adjustment with ctrl key pressed
Expand Down

0 comments on commit 874809e

Please sign in to comment.