Class JNIThemeInfoMacOS
- java.lang.Object
-
- com.github.weisj.darklaf.platform.macos.JNIThemeInfoMacOS
-
public class JNIThemeInfoMacOS extends Object
-
-
Constructor Summary
Constructors Constructor Description JNIThemeInfoMacOS()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static longcreatePreferenceChangeListener(Runnable callback)Create an preference change listener.static voiddeletePreferenceChangeListener(long listenerPtr)Delete the preference change listener.static ColorgetAccentColor()Returns the current accent color.static ColorgetSelectionColor()Returns the current selection color.static booleanisDarkThemeEnabled()Returns whether dark mode is enabled.static booleanisHighContrastEnabled()Returns whether high contrast mode is enabled.static voidpatchAppBundle(boolean isJava11OrOlder)static voidunpatchAppBundle()
-
-
-
Method Detail
-
isDarkThemeEnabled
public static boolean isDarkThemeEnabled()
Returns whether dark mode is enabled.- Returns:
- true if dark mode is enabled.
-
isHighContrastEnabled
public static boolean isHighContrastEnabled()
Returns whether high contrast mode is enabled.- Returns:
- true if high contrast mode is enabled.
-
getAccentColor
public static Color getAccentColor()
Returns the current accent color.- Returns:
- the accent color.
-
getSelectionColor
public static Color getSelectionColor()
Returns the current selection color.- Returns:
- the current selection color.
-
createPreferenceChangeListener
public static long createPreferenceChangeListener(Runnable callback)
Create an preference change listener.- Parameters:
callback- the event callback.- Returns:
- the pointer to the listener.
-
deletePreferenceChangeListener
public static void deletePreferenceChangeListener(long listenerPtr)
Delete the preference change listener.- Parameters:
listenerPtr- pointer to the listener.
-
patchAppBundle
public static void patchAppBundle(boolean isJava11OrOlder)
-
unpatchAppBundle
public static void unpatchAppBundle()
-
-