From 59757c3be509a71e50ce57e031f298469baca75e Mon Sep 17 00:00:00 2001 From: biwa <6475593+biwa@users.noreply.github.com> Date: Sat, 2 Jul 2022 19:25:10 +0200 Subject: [PATCH] Sound Environment Mode: fixed a crash that happened when exiting Draw Lines Mode with the "edit" action and returning to Sound Environment Mode. Fixes #755 --- .../SoundPropagationMode/SoundEnvironmentMode.cs | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Source/Plugins/SoundPropagationMode/SoundEnvironmentMode.cs b/Source/Plugins/SoundPropagationMode/SoundEnvironmentMode.cs index 2516c3d2..0a353705 100755 --- a/Source/Plugins/SoundPropagationMode/SoundEnvironmentMode.cs +++ b/Source/Plugins/SoundPropagationMode/SoundEnvironmentMode.cs @@ -219,9 +219,20 @@ namespace CodeImp.DoomBuilder.SoundPropagationMode } } + protected override void OnEditBegin() + { + base.OnEditBegin(); + + editpressed = true; + } + //mxd. Show Reverb selector dialog or add a new sound environment thing protected override void OnEditEnd() { + // Edit pressed in this mode? + if (!editpressed) + return; + if(highlightedthing != null) { ReverbsPickerForm form = new ReverbsPickerForm(highlightedthing);