fix(audio): starting the monitor restarts a running one instead of refusing
'Monitor already running' surfaced as the speakers checkbox unticking itself the instant it was ticked, whenever the UI's idea of the state and the real monitor had drifted apart. Stop-then-start makes the button mean what it says.
This commit is contained in:
@@ -10681,6 +10681,11 @@ func (a *App) AudioStartMonitor() error {
|
||||
return fmt.Errorf("audio not initialized")
|
||||
}
|
||||
cfg, _ := a.GetAudioSettings()
|
||||
// Idempotent: asking to listen while a monitor is already running restarts
|
||||
// it instead of refusing. The refusal surfaced as a checkbox that unticked
|
||||
// itself the instant it was ticked, whenever the UI's idea of the state and
|
||||
// the real monitor had drifted apart.
|
||||
a.audioMgr.StopMonitor()
|
||||
// When the rig's audio arrives over the NETWORK (Icom 50003), the monitor
|
||||
// must be render-only: this button used to start a USB capture from the
|
||||
// "From radio" device as well, and that second producer — often another
|
||||
|
||||
Reference in New Issue
Block a user