Example #1
0
        public static bool IsNotInteractingTouchpad(BaseInputCapture bic, ControllersInteractionType cit, InteractionThumbPosition itp, TouchpadInputCapture tic, bool checkingYAxis = false, bool checkingXAxis = true)
        {
            if (cit.HasClickInteraction)
            {
                return(!bic.IsClicking || (checkingYAxis && Math.Abs(tic.ThumbPosition.y) < itp.IsClickingThreshold) || (checkingXAxis && Math.Abs(tic.ThumbPosition.x) < itp.IsClickingThreshold));
            }

            if (cit.HasTouchInteraction)
            {
                return(!bic.IsTouching || (checkingYAxis && Math.Abs(tic.ThumbPosition.y) < itp.IsTouchingThreshold) || (checkingXAxis && Math.Abs(tic.ThumbPosition.x) < itp.IsTouchingThreshold));
            }

            return(false);
        }
Example #2
0
 public static bool IsNotInteracting(BaseInputCapture bic, ControllersInteractionType cit)
 {
     return((cit.HasClickInteraction && !bic.IsClicking) || (cit.HasTouchInteraction && !bic.IsTouching));
 }