Invalid audio output hangs when clicking a note
Steps to reproduce:
1) Create a project.
2) Put some notes in.
3) Make sure the audio output is invalid. (If this is the case, attempting to play will not advance the playhead. At this point, 'play' can still be stopped as expected.)
- To achieve this state on my device, a Samsung Galaxy Book Pro, plug in some headphones, go into Edit > Preferences > I/O, make sure PortAudio is selected, make sure the headphones are the selected Device, click Restart Audio and Midi Devices, unplug the headphones, DO NOT click Restart Audio and Midi Devices. This will guarantee the audio output is invalid. Unsure how to reproduce on other systems as audio tends to switch devices automatically.
4) Click a note.
Expected: The program will not hang. Obviously no audio will be played as the output is invalid; however, it should otherwise act consistent as if the note were played normally.
Actual: The program hangs, and must be killed in task manager or through the "program is not responding" dialog.
Workaround: Make sure to click Restart Audio and MIDI devices every time you disconnect or otherwise invalidate an audio device, or if it does so by itself.
OS: Windows 10 (10.0), Arch.: x86_64, MuseScore version (64-bit): 188.8.131.528021803, revision: 3224f34
Almost certainly related to #326369: hang during note entry -> caused by non-operational audio output.