blob: 8283d4caf7d5db7fc263ac064e47f1506978c251 [file] [log] [blame]
# Copyright (c) 2012 The Chromium OS Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
from fuzzy_check import FuzzyCheck
from validators import *
# originally generated gestures:
# ButtonDown(1)
# FlingStop
# FlingStop
# Motion d=716 x=100 y=703 r=0.25
def Validate(raw, events, gestures):
fuzzy = FuzzyCheck()
fuzzy.expected = [
ButtonDownValidator(1),
MotionValidator(end=">19", merge=True),
]
fuzzy.unexpected = [
MotionValidator("<10"),
FlingStopValidator("<10"),
]
return fuzzy.Check(gestures)