Bug 864684 - Prevent two way scrolling if it is not necessary

If the browser content is scrollable, every single touch move event makes two way scrolling(scrollTop, scrollLeft) even though the content only can be scrolled in one way(vertically or horizontally). So, prevent two way scrolling if it is not necessary.