blob: 5234811fc90c7e92c99e18f5e7e497347f097b05 [file] [log] [blame]
# Copyright (c) 2013 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:
# FlingStop
# Motion d=11.2 x=9.913 y=4.077 r=0.2405 s=96.68
# FlingStop
# ButtonDown(4)
# ButtonUp(4)
def Validate(raw, events, gestures):
fuzzy = FuzzyCheck()
fuzzy.expected = [
MotionValidator(merge=True),
ButtonDownValidator(1),
ButtonUpValidator(1),
]
fuzzy.unexpected = [
FlingStopValidator("<10"),
]
return fuzzy.Check(gestures)