Exemple #1
0
        protected override void OnMouseDown(SwipeArgs args, GameObject instance)
        {
            targetDepth = GetTransformDepth(instance.transform);

            if (Selection.gameObjects.Length > 1 && Selection.Contains(instance))
            {
                isSelectionBounded = true;
            }
        }
        protected override bool OnSwipeValidate(SwipeArgs args, GameObject instance)
        {
            if (targetState != args.isActive)
            {
                return(false);
            }

            var depth = GetTransformDepth(instance.transform);

            if (depth != targetDepth)
            {
                return(false);
            }

            if (isSelectionBounded && !Selection.Contains(instance))
            {
                return(false);
            }

            return(true);
        }
Exemple #3
0
 protected virtual void OnMouseDown(SwipeArgs args, T userData)
 {
 }
Exemple #4
0
 protected virtual void OnStartDragging(SwipeArgs args)
 {
 }
Exemple #5
0
 protected virtual bool OnSwipeValidate(SwipeArgs args, T userData)
 {
     return(targetState == args.isActive);
 }
Exemple #6
0
 protected virtual void OnMouseDown(SwipeArgs args, T userData)
 {
     targetState = args.isActive;
 }