mirror of
https://github.com/processing/processing4.git
synced 2026-02-06 15:19:39 +01:00
Hoisting some common preprocessor bits up into the superclass in preparation for the new preproc.
This commit is contained in:
@@ -28,52 +28,13 @@ import java.io.*;
|
||||
|
||||
|
||||
public class PdePreprocessorOro extends PdePreprocessor {
|
||||
//static final String EXTENDS = "extends BApplet ";
|
||||
//static final String EXTENDS_KJC = "extends KjcApplet ";
|
||||
|
||||
static final String applet_imports[] = {
|
||||
"java.applet", "java.awt", "java.awt.image", "java.awt.event",
|
||||
"java.io", "java.net", "java.text", "java.util", "java.util.zip"
|
||||
};
|
||||
|
||||
static final String application_imports[] = {
|
||||
"java.applet", "java.awt", "java.awt.image", "java.awt.event",
|
||||
"java.io", "java.net", "java.text", "java.util", "java.util.zip",
|
||||
"javax.comm",
|
||||
|
||||
// if jdk14 defined, jdk13 will be as well
|
||||
#ifdef JDK13
|
||||
"javax.sound.midi", "javax.sound.midi.spi",
|
||||
"javax.sound.sampled", "javax.sound.sampled.spi",
|
||||
#endif
|
||||
|
||||
#ifdef JDK14
|
||||
"javax.xml.parsers", "javax.xml.transform",
|
||||
"javax.xml.transform.dom", "javax.xml.transform.sax",
|
||||
"javax.xml.transform.stream", "org.xml.sax",
|
||||
"org.xml.sax.ext", "org.xml.sax.helpers"
|
||||
#endif
|
||||
};
|
||||
|
||||
String program;
|
||||
String buildPath;
|
||||
boolean usingExternal; // use an external process to display the applet?
|
||||
|
||||
String tempClass;
|
||||
String tempFilename;
|
||||
String tempClassFilename;
|
||||
|
||||
public PdePreprocessorOro(String program, String buildPath) {
|
||||
this.program = program;
|
||||
this.buildPath = buildPath;
|
||||
|
||||
usingExternal = PdeBase.getBoolean("play.external", false);
|
||||
super(program, buildPath);
|
||||
}
|
||||
|
||||
static final int BEGINNER = 0;
|
||||
static final int INTERMEDIATE = 1;
|
||||
static final int ADVANCED = 2;
|
||||
|
||||
// writes .java file into buildPath
|
||||
public String writeJava(String name, boolean extendsNormal,
|
||||
boolean exporting) {
|
||||
|
||||
Reference in New Issue
Block a user