Skip to content
Commit c28c8b74 authored by Georg Gadinger's avatar Georg Gadinger 🐾 Committed by Nicolas Fella
Browse files

KColorSchemeWatcherMac: do not use new NSAppearance API on older macOS versions

On macOS versions older than Big Sur (11.0) the
`NSAppearance.currentDrawingAppearance` property does not exist, and
trying to use it will crash the app at runtime.

This commit makes sure the new property is used on Big Sur or newer
macOS releases, and uses the deprecated `NSAppearance.currentAppearance`
property on Mojave (10.14) or newer.  As the light/dark mode switch was
introduced in Mojave, running the app on older releases will always
prefer the light mode.

Tested on macOS 10.15.5 (x86_64) and 13.1 (arm64)

BUG: 463752
parent 92e12f18
Pipeline #303977 passed with stage
in 16 minutes and 27 seconds
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment