mirror of
https://git.do.srb2.org/STJr/ZoneBuilder.git
synced 2025-03-13 22:23:20 +00:00
Editing modes: fixed some crashes related to undoing/redoing while objects with associations were highlighted
This commit is contained in:
parent
76e68f6c9a
commit
60a010efd1
3 changed files with 24 additions and 0 deletions
|
@ -938,6 +938,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.Map.ConvertSelection(SelectionType.Linedefs);
|
||||
}
|
||||
|
||||
// If something is highlighted make sure to update the association so that it contains valid data
|
||||
if (highlighted != null && !highlighted.IsDisposed)
|
||||
highlightasso.Set(highlighted);
|
||||
|
||||
// Update selection info and labels
|
||||
UpdateSelectionInfo();
|
||||
SetupSectorLabels();
|
||||
|
@ -955,6 +959,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.Map.ConvertSelection(SelectionType.Linedefs);
|
||||
}
|
||||
|
||||
// If something is highlighted make sure to update the association so that it contains valid data
|
||||
if (highlighted != null && !highlighted.IsDisposed)
|
||||
highlightasso.Set(highlighted);
|
||||
|
||||
// Update selection info and labels
|
||||
UpdateSelectionInfo();
|
||||
SetupSectorLabels();
|
||||
|
|
|
@ -1502,6 +1502,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.Map.ConvertSelection(SelectionType.Sectors);
|
||||
}
|
||||
|
||||
// If something is highlighted make sure to update the association so that it contains valid data
|
||||
if (highlighted != null && !highlighted.IsDisposed)
|
||||
highlightasso.Set(highlighted);
|
||||
|
||||
// Clear labels
|
||||
SetupLabels();
|
||||
UpdateEffectLabels(); //mxd
|
||||
|
@ -1531,6 +1535,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.Map.ConvertSelection(SelectionType.Sectors);
|
||||
}
|
||||
|
||||
// If something is highlighted make sure to update the association so that it contains valid data
|
||||
if (highlighted != null && !highlighted.IsDisposed)
|
||||
highlightasso.Set(highlighted);
|
||||
|
||||
// Clear labels
|
||||
SetupLabels();
|
||||
UpdateEffectLabels(); //mxd
|
||||
|
|
|
@ -570,6 +570,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.Map.SelectMarkedGeometry(true, true);
|
||||
}
|
||||
|
||||
// If something is highlighted make sure to update the association so that it contains valid data
|
||||
if (highlighted != null && !highlighted.IsDisposed)
|
||||
highlightasso.Set(highlighted);
|
||||
|
||||
UpdateSelectionInfo(); // Update selection info and labels
|
||||
UpdateHelperObjects(); // Update helper lines
|
||||
SetupSectorLabels(); // And sector labels
|
||||
|
@ -586,6 +590,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
General.Map.Map.SelectMarkedGeometry(true, true);
|
||||
}
|
||||
|
||||
// If something is highlighted make sure to update the association so that it contains valid data
|
||||
if (highlighted != null && !highlighted.IsDisposed)
|
||||
highlightasso.Set(highlighted);
|
||||
|
||||
UpdateSelectionInfo(); // Update selection info and labels
|
||||
UpdateHelperObjects(); // Update helper lines
|
||||
SetupSectorLabels(); // And sector labels
|
||||
|
|
Loading…
Reference in a new issue