Optimize scrolling when trackpad is used