mirror of
https://git.do.srb2.org/STJr/UltimateZoneBuilder.git
synced 2025-05-30 16:41:38 +00:00
- Fixed immediate right-click-drag in Brightness mode
- Fixed potential crash and "ghost thing" left-over after cancelling pasted things
This commit is contained in:
parent
574de14915
commit
1fc8947d29
6 changed files with 7 additions and 52 deletions
|
@ -674,7 +674,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
{
|
||||
// Make the highlight a selection if we have a highlight
|
||||
if((highlighted != null) && !highlighted.IsDisposed)
|
||||
{
|
||||
SelectSector(highlighted, true, false);
|
||||
orderedselection.Add(highlighted);
|
||||
}
|
||||
}
|
||||
|
||||
// Anything selected?
|
||||
|
|
|
@ -951,6 +951,10 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
modealreadyswitching = true;
|
||||
this.OnAccept();
|
||||
}
|
||||
|
||||
// Update
|
||||
General.Map.ThingsFilter.Update();
|
||||
General.Interface.RedrawDisplay();
|
||||
|
||||
// Hide highlight info
|
||||
General.Interface.HideInfo();
|
||||
|
|
|
@ -519,19 +519,6 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
return base.OnCopyBegin();
|
||||
}
|
||||
|
||||
// When pasting
|
||||
public override bool OnPasteBegin()
|
||||
{
|
||||
// No selection made? But we have a highlight!
|
||||
if((General.Map.Map.GetSelectedLinedefs(true).Count == 0) && (highlighted != null))
|
||||
{
|
||||
// Make the highlight the selection
|
||||
highlighted.Selected = true;
|
||||
}
|
||||
|
||||
return base.OnPasteBegin();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region ================== Actions
|
||||
|
|
|
@ -797,19 +797,6 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
return base.OnCopyBegin();
|
||||
}
|
||||
|
||||
// When pasting
|
||||
public override bool OnPasteBegin()
|
||||
{
|
||||
// No selection made? But we have a highlight!
|
||||
if((General.Map.Map.GetSelectedSectors(true).Count == 0) && (highlighted != null))
|
||||
{
|
||||
// Make the highlight the selection
|
||||
SelectSector(highlighted, true, true);
|
||||
}
|
||||
|
||||
return base.OnPasteBegin();
|
||||
}
|
||||
|
||||
// When undo is used
|
||||
public override bool OnUndoBegin()
|
||||
{
|
||||
|
|
|
@ -498,19 +498,6 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
return base.OnCopyBegin();
|
||||
}
|
||||
|
||||
// When pasting
|
||||
public override bool OnPasteBegin()
|
||||
{
|
||||
// No selection made? But we have a highlight!
|
||||
if((General.Map.Map.GetSelectedThings(true).Count == 0) && (highlighted != null))
|
||||
{
|
||||
// Make the highlight the selection
|
||||
highlighted.Selected = true;
|
||||
}
|
||||
|
||||
return base.OnPasteBegin();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region ================== Actions
|
||||
|
|
|
@ -466,19 +466,6 @@ namespace CodeImp.DoomBuilder.BuilderModes
|
|||
return base.OnCopyBegin();
|
||||
}
|
||||
|
||||
// When pasting
|
||||
public override bool OnPasteBegin()
|
||||
{
|
||||
// No selection made? But we have a highlight!
|
||||
if((General.Map.Map.GetSelectedVertices(true).Count == 0) && (highlighted != null))
|
||||
{
|
||||
// Make the highlight the selection
|
||||
highlighted.Selected = true;
|
||||
}
|
||||
|
||||
return base.OnPasteBegin();
|
||||
}
|
||||
|
||||
#endregion
|
||||
|
||||
#region ================== Actions
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue