fix for issue #465

Issue
-
issue described in #465

Test case
-
clicking sidemenu button and scrolling was toggling sidemenu

Fix
-
`if (Math.abs(dy - startY) > Math.abs(dx - startX)) return true` moved this check for scrolling before setting `doMenu=true;`. This will prevent sidemenu toggle while scrolling.
(No real change in code, just moved around the checkers)