Skip to content

Commit

Permalink
Update input.js
Browse files Browse the repository at this point in the history
  • Loading branch information
atsar committed May 18, 2016
1 parent 8e69a36 commit c0ea7d8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/input.js
Original file line number Diff line number Diff line change
Expand Up @@ -379,7 +379,7 @@ function getAngle(p1, p2, props) {
* @return {Number} rotation
*/
function getRotation(start, end) {
return getAngle(end[1], end[0], PROPS_CLIENT_XY) + getAngle(start[1], start[0], PROPS_CLIENT_XY);
return getAngle(end[1], end[0], PROPS_CLIENT_XY) - getAngle(start[1], start[0], PROPS_CLIENT_XY);
}

/**
Expand Down

1 comment on commit c0ea7d8

@atsar
Copy link
Author

@atsar atsar commented on c0ea7d8 May 18, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rotation bugfix.

Please sign in to comment.