diff --git a/internal/audio/recorder/recorder.go b/internal/audio/recorder/recorder.go index a76fd0d..42808e5 100644 --- a/internal/audio/recorder/recorder.go +++ b/internal/audio/recorder/recorder.go @@ -202,14 +202,14 @@ func (r *AudioRecorder) Stop() error { return nil } - // Stop device capture without uninitializing hardware + // Stop and release the capture device so Linux privacy indicators turn off + // between recordings. The next Start will initialize it again. if r.device != nil { if err := r.device.Stop(); err != nil { logger.Error("Failed to stop audio device: %v", err) - // On failure, it might be safer to uninit - r.device.Uninit() - r.device = nil } + r.device.Uninit() + r.device = nil } // Finalize WAV file diff --git a/text_insert_linux.go b/text_insert_linux.go index c9c1bad..50c243f 100644 --- a/text_insert_linux.go +++ b/text_insert_linux.go @@ -52,11 +52,11 @@ func (a *App) insertTranscription(text string) { func (a *App) releaseLinuxInputFocus() { if a.ctx == nil { - time.Sleep(150 * time.Millisecond) + time.Sleep(100 * time.Millisecond) return } wailsruntime.WindowHide(a.ctx) - time.Sleep(250 * time.Millisecond) + time.Sleep(150 * time.Millisecond) } func isASCII(text string) bool {