You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pivot.apache.org by "Sandro Martini (JIRA)" <ji...@apache.org> on 2014/05/20 12:44:38 UTC
[jira] [Commented] (PIVOT-949) bxml:script using js file doesn't
work on Java 7 or 8
[ https://issues.apache.org/jira/browse/PIVOT-949?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14003066#comment-14003066 ]
Sandro Martini commented on PIVOT-949:
--------------------------------------
Hi,
are you sure you are using Pivot-2.0.3 ? And are you sure that with Java 6 all is good while using Java 7 not ?
Could you attach here a minimal sample of your project ?
Anyway it's strange ... because absolute paths in bxml is a thing changed many time ago ... I suggest to use a relative path (as you can find in all our samples and tests). Under our tests subproject you can find some examples, like pivot_843.bxml, and a not-so-trivial example JavascriptConsoleTest and related files like javascript_console_test.bxml .
For some info take a look here:
http://pivot.apache.org/tutorials/bxml-primer.html
Let us know if you still have problems, or in a few weeks I'll close this issue ...
> bxml:script using js file doesn't work on Java 7 or 8
> -----------------------------------------------------
>
> Key: PIVOT-949
> URL: https://issues.apache.org/jira/browse/PIVOT-949
> Project: Pivot
> Issue Type: Bug
> Components: core-serialization
> Affects Versions: 2.0.3
> Environment: Windows 7
> Java 1.7
> Reporter: Said SAID EL IMAM
> Assignee: Sandro Martini
> Labels: javascript
> Fix For: 2.1, 2.0.5
>
>
> Hi,
> I use in my bxml files lines like:
> <bxml:script src="/gui/pivot/scripts/variables.js" />
> which loads some variables that I can use in the file by calling them like $icon
> But when using a Java version higher than 6, I get this error:
> org.apache.pivot.serialization.SerializationException: Value "icon" is not defined.
> at org.apache.pivot.beans.BXMLSerializer.processAttributes(BXMLSerializer.java:1093)
> at org.apache.pivot.beans.BXMLSerializer.processStartElement(BXMLSerializer.java:819)
> at org.apache.pivot.beans.BXMLSerializer.readObject(BXMLSerializer.java:443)
> at org.apache.pivot.beans.BXMLSerializer.processStartElement(BXMLSerializer.java:910)
> at org.apache.pivot.beans.BXMLSerializer.readObject(BXMLSerializer.java:443)
> at org.apache.pivot.beans.BXMLSerializer.readObject(BXMLSerializer.java:634)
> at org.apache.pivot.beans.BXMLSerializer.readObject(BXMLSerializer.java:607)
> at dcp.main.gui.pivot.Master.startup(Master.java:190)
> at org.apache.pivot.wtk.DesktopApplicationContext$2.run(DesktopApplicationContext.java:641)
> at org.apache.pivot.wtk.ApplicationContext$QueuedCallback.run(ApplicationContext.java:1607)
> at java.awt.event.InvocationEvent.dispatch(Unknown Source)
> at java.awt.EventQueue.dispatchEventImpl(Unknown Source)
> at java.awt.EventQueue.access$400(Unknown Source)
> at java.awt.EventQueue$3.run(Unknown Source)
> at java.awt.EventQueue$3.run(Unknown Source)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.security.ProtectionDomain$1.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)
> And my application shows a popup window with the message:
> Value "icon" is not defined.
--
This message was sent by Atlassian JIRA
(v6.2#6252)