From: gmungoc Date: Fri, 21 Dec 2018 11:06:37 +0000 (+0000) Subject: JAL-3032 prefer Jalview.isJS() to j2sNative X-Git-Tag: Release_2_11_4_0~45^2~18^2~334^2 X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=47ca18b4cfc7db54fc55a91fe5f0d61be989abf8;p=jalview.git JAL-3032 prefer Jalview.isJS() to j2sNative --- diff --git a/src/jalview/io/JalviewFileChooser.java b/src/jalview/io/JalviewFileChooser.java index c275ef0..56b8637 100755 --- a/src/jalview/io/JalviewFileChooser.java +++ b/src/jalview/io/JalviewFileChooser.java @@ -22,6 +22,7 @@ package jalview.io; import jalview.bin.Cache; +import jalview.bin.Jalview; import jalview.gui.JvOptionPane; import jalview.util.MessageManager; import jalview.util.Platform; @@ -193,15 +194,13 @@ public class JalviewFileChooser extends JFileChooser implements DialogRunnerI, { int value = super.showOpenDialog(this); - /* - * code below here is not reached in JalviewJS, instead - * propertyChange() is called for dialog action - */ - /** - * @j2sNative - */ + if (!Jalview.isJS()) { - handleResponse(value); + /* + * code here is not run in JalviewJS, instead + * propertyChange() is called for dialog action + */ + handleResponse(value); } return value; }