Hi everyone,
I was wondering whether anyone else have run into this issue as I have recently. I am using Processing 2.0a4 with the latest version of Export as ProcessingJS tool.
I used a very simple sample code to test whether the tool works properly. The code is as below.
void setup() {
size(300, 300);
background(40);
}
I saved it and fired the Export as Processing.js tool. The text area in the PDE then spit out the following error message. I tried the tool with Processing 1.5.1 as well and got the same error message which made me think that the issue is caused by the processing.js file included in the tool. Is there anybody else who has run into the same issue can help?
Thank you for your time in advance.
-Frank
//----------------The error message start below--------------------------
org.mozilla.javascript.EcmaError: TypeError: Cannot set property head that has only a getter. (processing.js#31)
Exception in thread "AWT-EventQueue-0" org.mozilla.javascript.EcmaError: ReferenceError: "Processing" is not defined. (<inline de.bezier.tools.export.PJSConverterEnvironment>#1)
at org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3654)
at org.mozilla.javascript.ScriptRuntime.constructError(ScriptRuntime.java:3632)
at org.mozilla.javascript.ScriptRuntime.notFoundError(ScriptRuntime.java:3717)
at org.mozilla.javascript.ScriptRuntime.name(ScriptRuntime.java:1692)
at org.mozilla.javascript.Interpreter.interpretLoop(Interpreter.java:3410)
at script(<inline de.bezier.tools.export.PJSConverterEnvironment>:1)
at org.mozilla.javascript.Interpreter.interpret(Interpreter.java:2487)
at org.mozilla.javascript.InterpretedFunction.call(InterpretedFunction.java:164)
at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:398)
at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3065)
at org.mozilla.javascript.InterpretedFunction.exec(InterpretedFunction.java:175)
at org.mozilla.javascript.Context.evaluateString(Context.java:1104)
at de.bezier.tools.export.ProcessingJSConverter.convert(Unknown Source)
at de.bezier.tools.export.ProcessingJS.exportApplet(Unknown Source)
at de.bezier.tools.export.ProcessingJS.run(Unknown Source)
at processing.app.contrib.ToolContribution.run(ToolContribution.java:227)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:677)
at java.awt.EventQueue.access$000(EventQueue.java:85)
at java.awt.EventQueue$1.run(EventQueue.java:638)
at java.awt.EventQueue$1.run(EventQueue.java:636)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:647)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
1