From c0b70cb41c9a4b50ff2e366a73bd0e8cf282bfbd Mon Sep 17 00:00:00 2001 From: Terry MacDonald Date: Wed, 21 Apr 2021 21:41:36 +1200 Subject: [PATCH] Fixing audio and capture permanence --- DisplayMagician/ShortcutRepository.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/DisplayMagician/ShortcutRepository.cs b/DisplayMagician/ShortcutRepository.cs index 83ca59a..90be55c 100644 --- a/DisplayMagician/ShortcutRepository.cs +++ b/DisplayMagician/ShortcutRepository.cs @@ -1332,7 +1332,7 @@ namespace DisplayMagician // Change Audio Device back (if one specified) if (activeAudioDevices.Count > 0) { - if (needToChangeAudioDevice) + if (needToChangeAudioDevice && shortcutToUse.AudioPermanence == ShortcutPermanence.Temporary) { logger.Debug($"ShortcutRepository/RunShortcut: Reverting default audio back to {rollbackAudioDevice.Name} audio device"); // use the Audio Device @@ -1363,7 +1363,7 @@ namespace DisplayMagician // Change Capture Device back (if one specified) if (activeCaptureDevices.Count > 0) { - if (needToChangeCaptureDevice) + if (needToChangeCaptureDevice && shortcutToUse.CapturePermanence == ShortcutPermanence.Temporary) { logger.Debug($"ShortcutRepository/RunShortcut: Reverting default capture (microphone) device back to {rollbackCaptureDevice.Name} capture device"); // use the Audio Device