changed onpan function signature as it is called by x and y co-ordinates seperatly, not with object
Merge pull request #3158 from rushi216/master

changed onpan function signature as it is called by x and y co-ordinates