Pan gesture

implements the pan gesture