From fb94c97efa4baf7887551b09642cf2598191ff40 Mon Sep 17 00:00:00 2001 From: Tres Finocchiaro Date: Wed, 2 Jun 2021 00:06:48 -0400 Subject: [PATCH] Add mask tray toggle for JDK17+ Closes #817 --- ant/project.properties | 3 +++ ant/unix/unix-launcher.sh.in | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/ant/project.properties b/ant/project.properties index 9c7d9db25..6cd2f427e 100644 --- a/ant/project.properties +++ b/ant/project.properties @@ -38,5 +38,8 @@ javafx.aarch64.version=17-ea+9_monocle javafx.aarch64.mirror=https://download2.gluonhq.com/openjfx/17 javafx.aarch64.arch=aarch64 +# Mask tray toggle (Apple only) +java.mask.tray=true + # Workaround to delay expansion of $${foo} (e.g. shell scripts) dollar=$ diff --git a/ant/unix/unix-launcher.sh.in b/ant/unix/unix-launcher.sh.in index 0ae629d77..c05fed936 100644 --- a/ant/unix/unix-launcher.sh.in +++ b/ant/unix/unix-launcher.sh.in @@ -96,7 +96,7 @@ if command -v java &>/dev/null; then else prefix="../../" # back two directories, e.g. postinstall fi - java $LAUNCH_OPTS -Xdock:name="$ABOUT_TITLE" -Xdock:icon="$ICON_PATH" -jar -Dapple.awt.UIElement="true" -Dapple.awt.enableTemplateImages="true" "${prefix}$PROPS_FILE.jar" -NSRequiresAquaSystemAppearance False "$@" + java $LAUNCH_OPTS -Xdock:name="$ABOUT_TITLE" -Xdock:icon="$ICON_PATH" -jar -Dapple.awt.UIElement="true" -Dapple.awt.enableTemplateImages="${java.mask.tray}" "${prefix}$PROPS_FILE.jar" -NSRequiresAquaSystemAppearance False "$@" else java $LAUNCH_OPTS -jar "$PROPS_FILE.jar" "$@" fi