Fix gesture bug