Improve compatibility of swipe gesture.

Resolve the conflict between swipe gesture and browser scrolling.