For reasons I won't bore you with at the moment, I wanted to put a customUI panel into a skin with a regular, non-compiled onload.bsh, and was having problems with it. So, I grabbed David's old demo skin for this,
https://jalbum.net/en/skins/skin/CustomEditUI , just to steal the code.
Lo and behold, this doesn't work in jAlbum 13 or 14. Specifically, if you try to edit one of the custom fields in image-editing mode (there is no regular settings panel at all), you get a console dump:
Exception in thread "AWT-EventQueue-0" java.security.PrivilegedActionException: java.security.PrivilegedActionException: bsh.EvalError: Command not found: saveUI() : at Line: 44 : in file: inline evaluation of: ``/** * This script is being run when a skin is selected * The script installs . . . '' : saveUI ( )
Called from method: focusLost : at Line: -1 : in file: <Called from Java Code> : <Compiled Java Code>
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue.dispatchEvent(Unknown Source)
at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
at java.awt.EventDispatchThread.run(Unknown Source)
Caused by: java.security.PrivilegedActionException: bsh.EvalError: Command not found: saveUI() : at Line: 44 : in file: inline evaluation of: ``/** * This script is being run when a skin is selected * The script installs . . . '' : saveUI ( )
Called from method: focusLost : at Line: -1 : in file: <Called from Java Code> : <Compiled Java Code>
at java.security.AccessController.doPrivileged(Native Method)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.security.ProtectionDomain$JavaSecurityAccessImpl.doIntersectionPrivilege(Unknown Source)
at java.awt.EventQueue$4.run(Unknown Source)
at java.awt.EventQueue$4.run(Unknown Source)
... 9 more
Caused by: bsh.EvalError: Command not found: saveUI() : at Line: 44 : in file: inline evaluation of: ``/** * This script is being run when a skin is selected * The script installs . . . '' : saveUI ( )
Called from method: focusLost : at Line: -1 : in file: <Called from Java Code> : <Compiled Java Code>
at bsh.Name.invokeLocalMethod(Name.java:953)
at bsh.Name.invokeMethod(Name.java:804)
at bsh.BSHMethodInvocation.eval(BSHMethodInvocation.java:75)
at bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:102)
at bsh.BSHPrimaryExpression.eval(BSHPrimaryExpression.java:47)
at bsh.BSHBlock.evalBlock(BSHBlock.java:130)
at bsh.BSHBlock.eval(BSHBlock.java:80)
at bsh.BshMethod.invokeImpl(BshMethod.java:362)
at bsh.BshMethod.invoke(BshMethod.java:258)
at bsh.BshMethod.invoke(BshMethod.java:186)
at bsh.This.invokeMethod(This.java:352)
at CustomUI$1.focusLost(BeanShell Generated via ASM (www.objectweb.org))
at java.awt.AWTEventMulticaster.focusLost(Unknown Source)
at java.awt.Component.processFocusEvent(Unknown Source)
at java.awt.Component.processEvent(Unknown Source)
at java.awt.Container.processEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.KeyboardFocusManager.redispatchEvent(Unknown Source)
at java.awt.DefaultKeyboardFocusManager.typeAheadAssertions(Unknown Source)
at java.awt.DefaultKeyboardFocusManager.dispatchEvent(Unknown Source)
at java.awt.Component.dispatchEventImpl(Unknown Source)
at java.awt.Container.dispatchEventImpl(Unknown Source)
at java.awt.Component.dispatchEvent(Unknown Source)
at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
at java.awt.EventQueue.access$500(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
at java.awt.EventQueue$3.run(Unknown Source)
... 14 more
Anyone have a clue? I haven't run into anything like this in a compiled UI.
Edited by: jGromit, to remove comma from link