From 8a10fcdd3159f6c3b2f5a13538a88376917bbe0e Mon Sep 17 00:00:00 2001 From: Istvan T <37590873+waydabber@users.noreply.github.com> Date: Thu, 7 Oct 2021 18:04:48 +0200 Subject: [PATCH] Fix volume control issue when only internal display is present (#680) --- MonitorControl/Info.plist | 2 +- MonitorControl/Support/MediaKeyTapManager.swift | 2 +- MonitorControlHelper/Info.plist | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/MonitorControl/Info.plist b/MonitorControl/Info.plist index c158f20..e59a995 100644 --- a/MonitorControl/Info.plist +++ b/MonitorControl/Info.plist @@ -19,7 +19,7 @@ CFBundleShortVersionString $(MARKETING_VERSION) CFBundleVersion - 6440 + 6443 LSApplicationCategoryType public.app-category.utilities LSMinimumSystemVersion diff --git a/MonitorControl/Support/MediaKeyTapManager.swift b/MonitorControl/Support/MediaKeyTapManager.swift index f6a446a..383c8a3 100644 --- a/MonitorControl/Support/MediaKeyTapManager.swift +++ b/MonitorControl/Support/MediaKeyTapManager.swift @@ -173,7 +173,7 @@ class MediaKeyTapManager: MediaKeyTapDelegate { keys.removeAll { keysToDelete.contains($0) } } // Remove volume related keys if audio device is controllable - if !isInternalDisplayOnly, let defaultAudioDevice = app.coreAudio.defaultOutputDevice { + if let defaultAudioDevice = app.coreAudio.defaultOutputDevice { let keysToDelete: [MediaKey] = [.volumeUp, .volumeDown, .mute] if !prefs.bool(forKey: PrefKey.allScreensVolume.rawValue), prefs.bool(forKey: PrefKey.useAudioDeviceNameMatching.rawValue) { if DisplayManager.shared.updateAudioControlTargetDisplays(deviceName: defaultAudioDevice.name) == 0 { diff --git a/MonitorControlHelper/Info.plist b/MonitorControlHelper/Info.plist index c1793f6..2896ee3 100644 --- a/MonitorControlHelper/Info.plist +++ b/MonitorControlHelper/Info.plist @@ -19,7 +19,7 @@ CFBundleShortVersionString $(MARKETING_VERSION) CFBundleVersion - 6440 + 6443 LSApplicationCategoryType public.app-category.utilities LSBackgroundOnly