adding pan gesture and delegate callBack