Skip to content
Extraits de code Groupes Projets
Sélectionner une révision Git
  • 0d92bc3d2b580d3057f83ba1a3abcd259fcf2f12
  • master par défaut
  • script
  • new-devel
  • devel
  • timingView-edit
  • fix-mpv
7 résultats

ThemeMac.mm

Blame
  • ThemeMac.mm 610 o
    #include "ThemeMac.hh"
    #include <AppKit/AppKit.h>
    
    #if !QT_MACOS_PLATFORM_SDK_EQUAL_OR_ABOVE(__MAC_10_14)
    @interface NSApplication (MojaveForwardDeclarations)
    @property (strong) NSAppearance *appearance NS_AVAILABLE_MAC(10_14);
    @end
    #endif
    
    namespace Vivy::Utils {
    void forceMacOSLightAquaApperance()
    {
    #if __has_builtin(__builtin_available)
        if (__builtin_available(macOS 10.14, *))
    #else // Xcode 8
        if (QOperatingSystemVersion::current() >= QOperatingSystemVersion(QOperatingSystemVersion::MacOS, 10, 14, 0))
    #endif
            NSApp.appearance = [NSAppearance appearanceNamed:NSAppearanceNameAqua];
    }
    
    }