Update associations when incrementing/decrementing tags

This commit is contained in:
spherallic 2023-05-09 00:51:11 +02:00
parent 3d398cc899
commit c97c025d7b
2 changed files with 20 additions and 0 deletions

View file

@ -2459,6 +2459,11 @@ namespace CodeImp.DoomBuilder.BuilderModes
else
General.Interface.DisplayStatus(StatusType.Action, "Incremented tag of one linedef to " + selected.First().Tag + ".");
// 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
General.Map.Map.Update();
General.Interface.RedrawDisplay();
@ -2493,6 +2498,11 @@ namespace CodeImp.DoomBuilder.BuilderModes
else
General.Interface.DisplayStatus(StatusType.Action, "Decremented tag of one linedef to " + selected.First().Tag + ".");
// 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
General.Map.Map.Update();
General.Interface.RedrawDisplay();

View file

@ -2665,6 +2665,11 @@ namespace CodeImp.DoomBuilder.BuilderModes
else
General.Interface.DisplayStatus(StatusType.Action, "Incremented tag of one sector to " + selected.First().Tag + ".");
// 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
UpdateSelectionInfo();
UpdateEffectLabels();
@ -2702,6 +2707,11 @@ namespace CodeImp.DoomBuilder.BuilderModes
else
General.Interface.DisplayStatus(StatusType.Action, "Decremented tag of one sector to " + selected.First().Tag + ".");
// 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
UpdateSelectionInfo();
UpdateEffectLabels();