Changed to work with hammerjs