void OnTouchesBegan(List <CCTouch> touches, CCEvent touchEvent) { touches = FindUniqueTouches(touches); if (touches.Count == 1) { var touch = touches[0]; _lastKnownPoint = touch.Location; _trackedShape = null; _lineRecognizer.Clear(); } else if (touches.Count > 1) { EvaluateResizeOrMoveStart(touches); } }
void EvaluateResizeOrMoveStart(List <CCTouch> touches) { touches = FindUniqueTouches(touches); var touch = touches [0]; _lastKnownPoint = touch.Location; if (_shapeNode.Children != null) { foreach (var obj in _shapeNode.Children) { if (obj is ShapeNode) { if (obj.BoundingBox.ContainsPoint(_lastKnownPoint)) { _trackedShape = obj as ShapeNode; } } } } }