We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0dabd60 commit ed3221cCopy full SHA for ed3221c
1 file changed
Src/LexText/LexTextControls/PhonologicalFeaturePopupTreeManager.cs
@@ -221,9 +221,12 @@ protected override void Dispose(bool disposing)
221
{
222
Cache.DomainDataByFlid.BeginUndoTask(LexTextControls.ksUndoInsertPhonologicalFeature,
223
LexTextControls.ksRedoInsertPhonologicalFeature);
224
- foreach (var cmBaseAnnotation in m_annotations)
+ foreach (var cmBaseAnnotation in m_annotations.ToList())
225
226
- cmBaseAnnotation.Delete();
+ if (cmBaseAnnotation.IsValidObject)
227
+ cmBaseAnnotation.Delete();
228
+ else
229
+ m_annotations.Remove(cmBaseAnnotation);
230
}
231
Cache.DomainDataByFlid.EndUndoTask();
232
0 commit comments