fix: mitigate macos 15 bugs with screencapture-kit (closes #5190)

This commit is contained in:
lwouis committed 2026-01-15 00:08:35 +01:00
1 parent 7c64864c2f
commit b2f5c6c4d5
1 file changed
+3 -1
+3 -1
View File
@@ -325,7 +325,9 @@ class Windows {
}
}
guard (!eligibleWindows.isEmpty || windowRemoved) else { return }
if #available(macOS 14.0, *) {
if #available(macOS 14.0, *),
// mitigate macOS 15 bugs with ScreenCapture Kit (see https://github.com/lwouis/alt-tab-macos/issues/5190)
ProcessInfo.processInfo.operatingSystemVersion.majorVersion != 15 {
WindowCaptureScreenshots.oneTimeScreenshots(eligibleWindows, source)
} else {
WindowCaptureScreenshotsPrivateApi.oneTimeScreenshots(eligibleWindows, source)