shithub: ft²

Download patch

ref: 411d88abb7c861e1410f52905b4f7d9b923b7316
parent: 9cf2fd9416bc0e3586e191fb732c7e7903bdce98
author: Olav Sørensen <olav.sorensen@live.no>
date: Tue Feb 22 07:29:26 EST 2022

Allow mouse button press to stop audio sampling (issue #31)

--- a/src/ft2_events.c
+++ b/src/ft2_events.c
@@ -447,8 +447,7 @@
 				 key != SDL_SCANCODE_AUDIOMUTE && key != SDL_SCANCODE_VOLUMEDOWN &&
 				 key != SDL_SCANCODE_VOLUMEUP))
 			{
-				// only let keyboard keys interrupt audio sampling
-				if (editor.samplingAudioFlag && eventType != SDL_MOUSEBUTTONDOWN)
+				if (editor.samplingAudioFlag)
 					stopSampling();
 
 				editor.wavIsRendering = false;