From 97708f316b561ec5f9f03d402945b522085b0d5b Mon Sep 17 00:00:00 2001 From: James Procter Date: Tue, 24 Jan 2023 07:48:07 +0000 Subject: [PATCH] =?utf8?q?JAL-629=20don=E2=80=99t=20trash=20user=E2=80=99s=20?= =?utf8?q?system=20property=20file=20when=20adjusting=20settings=20to=20proc?= =?utf8?q?ess=20CL=20args?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/jalview/bin/Cache.java | 19 +++++++++++++++---- src/jalview/bin/Commands.java | 4 ++++ 2 files changed, 19 insertions(+), 4 deletions(-) diff --git a/src/jalview/bin/Cache.java b/src/jalview/bin/Cache.java index 370a243..7ff7309 100755 --- a/src/jalview/bin/Cache.java +++ b/src/jalview/bin/Cache.java @@ -322,6 +322,16 @@ public class Cache private static boolean propsAreReadOnly = Platform.isJS(); + public static boolean isPropsAreReadOnly() + { + return propsAreReadOnly; + } + + public static void setPropsAreReadOnly(boolean propsAreReadOnly) + { + Cache.propsAreReadOnly = propsAreReadOnly; + } + private final static String JS_PROPERTY_PREFIX = "jalview_"; /** @@ -1401,10 +1411,11 @@ public class Cache if (customProxySet && // we have a username but no password for the scheme being // requested - (protocol.equalsIgnoreCase("http") - && (httpUser != null && httpUser.length() > 0 - && (httpPassword == null - || httpPassword.length == 0))) + (protocol.equalsIgnoreCase("http") + && (httpUser != null + && httpUser.length() > 0 + && (httpPassword == null + || httpPassword.length == 0))) || (protocol.equalsIgnoreCase("https") && (httpsUser != null && httpsUser.length() > 0 diff --git a/src/jalview/bin/Commands.java b/src/jalview/bin/Commands.java index 5b3e199..289d962 100644 --- a/src/jalview/bin/Commands.java +++ b/src/jalview/bin/Commands.java @@ -476,6 +476,10 @@ public class Commands } } } + // for moment we disable JSON export + Cache.setPropsAreReadOnly(true); + Cache.setProperty("EXPORT_EMBBED_BIOJSON", "false"); + switch (type) { case "svg": -- 1.7.10.2