public SingleHandedSwipeGesture(GestureHandType handsUsed, SingleHandedSwipeGestureDirectionType direction,
     double confidence, Point startPosition, Point endPosition)
 {
     HandsUsed = handsUsed;
     Direction = direction;
     Confidence = confidence;
     StartPosition = startPosition;
     EndPosition = endPosition;
     GestureSubType = GetGestureSubType(handsUsed, direction);
 }
        public static GestureSubType GetGestureSubType(GestureHandType handsUsed, SingleHandedSwipeGestureDirectionType direction)
        {
            if (handsUsed == GestureHandType.LeftHand && direction == SingleHandedSwipeGestureDirectionType.LeftToRight)
            {
                return GestureSubType.LeftHandedSwipeFromLeftToRight;
            }
            else if (handsUsed == GestureHandType.LeftHand && direction == SingleHandedSwipeGestureDirectionType.RightToLeft)
            {
                return GestureSubType.LeftHandedSwipeFromRightToLeft;
            }
            else if (handsUsed == GestureHandType.LeftHand && direction == SingleHandedSwipeGestureDirectionType.TopToBottom)
            {
                return GestureSubType.LeftHandedSwipeFromTopToBottom;
            }
            else if (handsUsed == GestureHandType.LeftHand && direction == SingleHandedSwipeGestureDirectionType.BottomToTop)
            {
                return GestureSubType.LeftHandedSwipeFromBottomToTop;
            }
            else if (handsUsed == GestureHandType.RightHand && direction == SingleHandedSwipeGestureDirectionType.LeftToRight)
            {
                return GestureSubType.RightHandedSwipeFromLeftToRight;
            }
            else if (handsUsed == GestureHandType.RightHand && direction == SingleHandedSwipeGestureDirectionType.RightToLeft)
            {
                return GestureSubType.RightHandedSwipeFromRightToLeft;
            }
            else if (handsUsed == GestureHandType.RightHand && direction == SingleHandedSwipeGestureDirectionType.TopToBottom)
            {
                return GestureSubType.RightHandedSwipeFromTopToBottom;
            }
            else if (handsUsed == GestureHandType.RightHand && direction == SingleHandedSwipeGestureDirectionType.BottomToTop)
            {
                return GestureSubType.RightHandedSwipeFromBottomToTop;
            }

            throw new InvalidOperationException();
        }
        public SingleHandedSwipeGestureRecognizer(GestureHandType handType, SingleHandedSwipeGestureDirectionType directionType)
        {
            if(handType == GestureHandType.BothHands)
            {
                throw new NotSupportedException();
            }

            hand = handType;
            direction = directionType;

            Reset(null);
        }
        public SingleHandedSwipeGestureRecognizer(GestureSubType subType)
        {
            switch (subType)
            {
                case GestureSubType.LeftHandedSwipeFromLeftToRight:
                    hand = GestureHandType.LeftHand;
                    direction = SingleHandedSwipeGestureDirectionType.LeftToRight;
                    break;
                case GestureSubType.LeftHandedSwipeFromRightToLeft:
                    hand = GestureHandType.LeftHand;
                    direction = SingleHandedSwipeGestureDirectionType.RightToLeft;
                    break;
                case GestureSubType.RightHandedSwipeFromLeftToRight:
                    hand = GestureHandType.RightHand;
                    direction = SingleHandedSwipeGestureDirectionType.LeftToRight;
                    break;
                case GestureSubType.RightHandedSwipeFromRightToLeft:
                    hand = GestureHandType.RightHand;
                    direction = SingleHandedSwipeGestureDirectionType.RightToLeft;
                    break;
                default:
                    throw new NotSupportedException();
            }

            Reset(null);
        }