From: hansonr Date: Mon, 29 Jul 2019 08:34:57 +0000 (+0200) Subject: JAL-3380 allows JalviewJS to get embedded div attributes X-Git-Url: http://source.jalview.org/gitweb/?p=jalview.git;a=commitdiff_plain;h=4afd9fc71fb19a511e9a2d17dbac1592eade1630 JAL-3380 allows JalviewJS to get embedded div attributes --- diff --git a/src/jalview/util/Platform.java b/src/jalview/util/Platform.java index e53d2a9..aaadbb9 100644 --- a/src/jalview/util/Platform.java +++ b/src/jalview/util/Platform.java @@ -832,4 +832,25 @@ public class Platform */ } + public final static String EMBEDDED_DIM = "dim"; + + /** + * + * If this frame Is this frame embedded in a web page, return a known type. + * + * @param frame + * a JFrame or JInternalFrame + * @param type + * @return null if frame is not embedded. + */ + public static Object getEmbeddedAttribute(Object frame, String type) + { + if (!isJS()) + { + return null; + } + return (/** swingjs@j2sNative || frame.ui.getEmbedded(type) */ + null); + } + }