예제 #1
0
        public void RemoveSelectedSpan() // removes selected (doh) span
        {
            if (Spans.Count <= 2)
            {
                return;
            }
            int index = Spans.IndexOf(_selectedSpan);

            _selectedSpan.PropertyChanged -= OnUserSpanPropertyChanged;
            Spans.Remove(_selectedSpan);

            OrderingSection();

            if (index >= Spans.Count())
            {
                return;                         // last span was removed so nothing to do
            }
            else
            {
                OnTowerAbscissaPropertyChanged(Spans[index]);  // altering span lengths as a consequence of the tower abscissas change (change of tower abscissa has higher priority than span length)
            }
            if (EvaluateNeedToPerformInternalIntegrityCheck())
            {
                CheckInternalIntegrity();
            }
        }
예제 #2
0
 public int GetSpanCount()
 {
     return(Spans.Count());
 }