aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/jsruntime/qv4globalobject_p.h
diff options
context:
space:
mode:
authorTor Arne Vestbø <[email protected]>2025-04-15 23:52:01 +0200
committerTor Arne Vestbø <[email protected]>2025-05-23 16:47:33 +0200
commitfa4568622cc19e5a876238d6cfca2e95936f8bdd (patch)
tree6af08b1cef90236a23fe77519a545bf5a06a9346 /src/qml/jsruntime/qv4globalobject_p.h
parent6ae7a5a89ea9ad0fdf61a1b4f78f555608407598 (diff)
macOS: Port from deprecated NSAppearance.currentAppearanceHEADdev
When the system appearance changes, it will be reflected through NSApp.effectiveAppearance, but NSAppearance.currentAppearance and NSAppearance.currentDrawingAppearance will remain as is for some reason (perhaps as a compatibility for apps that were not ready to handle dark mode). The original way to deal with this was to explicitly set the NSAppearance.currentAppearance to the new effective appearance, which would take effect for the thread from that point on. But this API has been deprecated, most likely because overriding it globally could mess up views or logic that was not prepared for dark mode). The replacement API, NSAppearance performAsCurrentDrawingAppearance is given a block, and will only override NSAppearance.currentAppearance during the block, which isolates it from other fragile components. We now use a helper from QtGui that takes care of wrapping our style drawing in performAsCurrentDrawingAppearance. Task-number: QTBUG-135789 Change-Id: I0eb5dfc05734cf75181e6a3ed8cf2d23185f425f Reviewed-by: Morten Johan Sørvig <[email protected]>
Diffstat (limited to 'src/qml/jsruntime/qv4globalobject_p.h')
0 files changed, 0 insertions, 0 deletions