private void UnlockAlignment() { if (_lockedAlignmentPlot != null) { _lockedAlignmentPlot.GetComponentInChildren <AxisAlignmentIndicator>()?.UnlockAlignment(_lockedAlignment); } _lockedAlignment = AlignmentType.Horizontal; _lockedAlignmentPlot = null; }
private void LockAlignment() { var mainAlignment = GetSortedAlignments().FirstOrDefault(); if (mainAlignment != null) { _lockedAlignment = mainAlignment.Item1; _lockedAlignmentPlot = mainAlignment.Item2; _lockedAlignmentPlot.GetComponentInChildren <AxisAlignmentIndicator>()?.LockAlignment(_lockedAlignment); } else { _lockedAlignment = AlignmentType.Horizontal; _lockedAlignmentPlot = null; } }