Beispiel #1
0
        private Finger findFinger(TouchInfo info)
        {
            Finger finger;

            if (!fingers.TryGetValue(info.id, out finger))
            {
                finger = fingerPool.getPooledObject();
                fingers.Add(info.id, finger);
                finger.setInfoOutOfPool(info.id, info.normalizedX, info.normalizedY, info.pixelX, info.pixelY);

                //This might happen in a touch started or touch moved event.
                if (FingerStarted != null)
                {
                    FingerStarted.Invoke(finger);
                }
            }
            return(finger);
        }