mirror of
https://github.com/MonitorControl/MonitorControl.git
synced 2026-05-15 14:15:55 -06:00
Improved dummy detection for newer versions of BetterDummy (#975)
This commit is contained in:
parent
b07d762c9b
commit
e2009a62ac
3 changed files with 6 additions and 6 deletions
|
|
@ -19,7 +19,7 @@
|
|||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(MARKETING_VERSION)</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>7029</string>
|
||||
<string>7030</string>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string>public.app-category.utilities</string>
|
||||
<key>LSMinimumSystemVersion</key>
|
||||
|
|
|
|||
|
|
@ -399,13 +399,13 @@ class DisplayManager {
|
|||
}
|
||||
|
||||
static func isDummy(displayID: CGDirectDisplayID) -> Bool {
|
||||
let vendorNumber = CGDisplayVendorNumber(displayID)
|
||||
let rawName = DisplayManager.getDisplayRawNameByID(displayID: displayID)
|
||||
var isDummy: Bool = false
|
||||
if rawName.lowercased().contains("dummy") {
|
||||
if rawName.lowercased().contains("dummy") || (self.isVirtual(displayID: displayID) && vendorNumber == UInt32(0xF0F0)) {
|
||||
os_log("NOTE: Display is a dummy!", type: .info)
|
||||
isDummy = true
|
||||
return true
|
||||
}
|
||||
return isDummy
|
||||
return false
|
||||
}
|
||||
|
||||
static func isVirtual(displayID: CGDirectDisplayID) -> Bool {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
<key>CFBundleShortVersionString</key>
|
||||
<string>$(MARKETING_VERSION)</string>
|
||||
<key>CFBundleVersion</key>
|
||||
<string>7029</string>
|
||||
<string>7030</string>
|
||||
<key>LSApplicationCategoryType</key>
|
||||
<string>public.app-category.utilities</string>
|
||||
<key>LSBackgroundOnly</key>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue