1 // package.js from Jmol project -- template only here for Swingjs
3 // NOTE: Any changes here must also be reflected in build xml
4 // NOTE: this code does not allow for multiple J2S applications on a page
6 if (!window["java.registered"])
7 window["java.registered"] = false;
9 (function (ClazzLoader) {
11 if (window["java.packaged"]) return;
12 window["java.packaged"] = true;
14 //if (!Jmol._isAsync) {
15 for (var i = 0; i < Jmol._coreFiles.length; i++)
16 ClazzLoader.loadZJar(Jmol._coreFiles[i], ClazzLoader.runtimeKeyClass);
19 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "java/awt/geom/Point2D.js", [
20 "java.awt.geom.Point2D",
21 "java.awt.geom.Point2D.Double",
22 "java.awt.geom.Point2D.Float"
25 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "jssun/awt/SunHints.js", [
27 "jssun.awt.SunHints.Value",
28 "jssun.awt.SunHints.Key",
29 "jssun.awt.SunHints.LCDContrastKey",
30 "jssun.awt.SunHints.SunKey"
33 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "javax/swing/text/AbstractDocument.js", [
34 "javax.swing.text.AbstractDocument",
35 "javax.swing.text.AbstractDocument.UndoRedoDocumentEvent"
38 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "javax/swing/Popup.js", [
40 "javax.swing.Popup.DefaultFrame",
41 "javax.swing.Popup.HeavyWeightWindow"
44 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "javax/swing/text/LayeredHighlighter.js", [
45 "javax.swing.text.LayeredHighlighter",
46 "javax.swing.text.LayeredHighlighter.LayerPainter"
49 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "javax/swing/JComponent.js", [
50 "javax.swing.JComponent",
51 "javax.swing.JComponent.KeyboardState",
52 "javax.swing.JComponent.ActionStandin",
53 "javax.swing.JComponent.IntVector"
56 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "jssun/util/resources/LocaleData.js", [
57 "jssun.util.resources.LocaleData",
58 "jssun.util.resources.LocaleDataResourceBundleControl"
61 ClazzLoader.jarClasspath (ClazzLoader.getJ2SLibBase() + "java/text/DateFormat.js", [
62 "java.text.DateFormat",
63 "java.text.DateFormat.Field"
69 var base = ClazzLoader.getJ2SLibBase() + "core/";
71 // note - we don't need to list ALL the classes -- only the ones that are entry points.
72 // several more classe are in each of these files -- see build_03_tojs.xml
75 ClazzLoader.jarClasspath (base + "coretext.z.js", [
78 "J.shape.Object2dShape",
84 "J.render.TextRenderer",
94 window["java.registered"] = true;