You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pivot.apache.org by gb...@apache.org on 2010/06/16 01:44:06 UTC
svn commit: r955094 - in /pivot/trunk/tools/src/org/apache/pivot/tools:
json/ wtk/ xml/
Author: gbrown
Date: Tue Jun 15 23:44:05 2010
New Revision: 955094
URL: http://svn.apache.org/viewvc?rev=955094&view=rev
Log:
Update tools to use BXML.
Added:
pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.bxml
- copied, changed from r954993, pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.wtkx
pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.bxml
- copied, changed from r954993, pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.wtkx
pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.bxml
- copied, changed from r954993, pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.wtkx
Removed:
pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.wtkx
pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.wtkx
pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.wtkx
Modified:
pivot/trunk/tools/src/org/apache/pivot/tools/json/JSONViewer.java
pivot/trunk/tools/src/org/apache/pivot/tools/wtk/EventLoggerSkin.java
pivot/trunk/tools/src/org/apache/pivot/tools/xml/XMLViewer.java
Modified: pivot/trunk/tools/src/org/apache/pivot/tools/json/JSONViewer.java
URL: http://svn.apache.org/viewvc/pivot/trunk/tools/src/org/apache/pivot/tools/json/JSONViewer.java?rev=955094&r1=955093&r2=955094&view=diff
==============================================================================
--- pivot/trunk/tools/src/org/apache/pivot/tools/json/JSONViewer.java (original)
+++ pivot/trunk/tools/src/org/apache/pivot/tools/json/JSONViewer.java Tue Jun 15 23:44:05 2010
@@ -62,11 +62,11 @@ public class JSONViewer implements Appli
@Override
public void startup(Display display, Map<String, String> properties)
throws Exception {
- BeanSerializer wtkxSerializer = new BeanSerializer();
- wtkxSerializer.put(APPLICATION_KEY, this);
+ BeanSerializer beanSerializer = new BeanSerializer();
+ beanSerializer.put(APPLICATION_KEY, this);
- window = (Window)wtkxSerializer.readObject(this, "json_viewer.wtkx");
- wtkxSerializer.bind(this);
+ window = (Window)beanSerializer.readObject(this, "json_viewer.bxml");
+ beanSerializer.bind(this);
Label prompt = new Label("Drag or paste JSON here");
prompt.getStyles().put("horizontalAlignment", HorizontalAlignment.CENTER);
Copied: pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.bxml (from r954993, pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.wtkx)
URL: http://svn.apache.org/viewvc/pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.bxml?p2=pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.bxml&p1=pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.wtkx&r1=954993&r2=955094&rev=955094&view=diff
==============================================================================
--- pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.wtkx (original)
+++ pivot/trunk/tools/src/org/apache/pivot/tools/json/json_viewer.bxml Tue Jun 15 23:44:05 2010
@@ -17,20 +17,20 @@ limitations under the License.
-->
<Window maximized="true"
- xmlns:wtkx="http://pivot.apache.org/wtkx"
+ xmlns:bxml="http://pivot.apache.org/bxml"
xmlns:content="org.apache.pivot.wtk.content"
xmlns="org.apache.pivot.wtk">
- <wtkx:script src="json_viewer.js"/>
+ <bxml:script src="json_viewer.js"/>
<Border styles="{color:10}">
<ScrollPane horizontalScrollBarPolicy="fill_to_capacity"
verticalScrollBarPolicy="fill_to_capacity">
- <TreeView wtkx:id="treeView" dropTarget="$treeViewDropTarget">
+ <TreeView bxml:id="treeView" dropTarget="$treeViewDropTarget">
<nodeRenderer>
<content:TreeViewNodeRenderer showIcon="false"/>
</nodeRenderer>
<componentKeyListeners>
- <wtkx:script>
+ <bxml:script>
<![CDATA[
importPackage(org.apache.pivot.wtk);
function keyPressed(component, keyCode, keyLocation) {
@@ -40,7 +40,7 @@ limitations under the License.
}
}
]]>
- </wtkx:script>
+ </bxml:script>
</componentKeyListeners>
</TreeView>
</ScrollPane>
Modified: pivot/trunk/tools/src/org/apache/pivot/tools/wtk/EventLoggerSkin.java
URL: http://svn.apache.org/viewvc/pivot/trunk/tools/src/org/apache/pivot/tools/wtk/EventLoggerSkin.java?rev=955094&r1=955093&r2=955094&view=diff
==============================================================================
--- pivot/trunk/tools/src/org/apache/pivot/tools/wtk/EventLoggerSkin.java (original)
+++ pivot/trunk/tools/src/org/apache/pivot/tools/wtk/EventLoggerSkin.java Tue Jun 15 23:44:05 2010
@@ -86,9 +86,9 @@ class EventLoggerSkin extends ContainerS
throw new RuntimeException(exception);
}
- BeanSerializer wtkxSerializer = new BeanSerializer(resources);
+ BeanSerializer beanSerializer = new BeanSerializer(resources);
try {
- content = (Component)wtkxSerializer.readObject(this, "event_logger_skin.wtkx");
+ content = (Component)beanSerializer.readObject(this, "event_logger_skin.bxml");
} catch (IOException exception) {
throw new RuntimeException(exception);
} catch (SerializationException exception) {
@@ -97,8 +97,8 @@ class EventLoggerSkin extends ContainerS
eventLogger.add(content);
- declaredEventsTreeView = wtkxSerializer.getValue("declaredEventsTreeView");
- firedEventsTableView = wtkxSerializer.getValue("firedEventsTableView");
+ declaredEventsTreeView = beanSerializer.getValue("declaredEventsTreeView");
+ firedEventsTableView = beanSerializer.getValue("firedEventsTableView");
// Propagate check state upwards or downwards as necessary
declaredEventsTreeView.getTreeViewNodeStateListeners().add(new TreeViewNodeStateListener() {
Copied: pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.bxml (from r954993, pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.wtkx)
URL: http://svn.apache.org/viewvc/pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.bxml?p2=pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.bxml&p1=pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.wtkx&r1=954993&r2=955094&rev=955094&view=diff
==============================================================================
--- pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.wtkx (original)
+++ pivot/trunk/tools/src/org/apache/pivot/tools/wtk/event_logger_skin.bxml Tue Jun 15 23:44:05 2010
@@ -17,13 +17,13 @@ limitations under the License.
-->
<SplitPane orientation="horizontal" splitRatio="0.25"
- xmlns:wtkx="http://pivot.apache.org/wtkx"
+ xmlns:bxml="http://pivot.apache.org/bxml"
xmlns:content="org.apache.pivot.wtk.content"
xmlns="org.apache.pivot.wtk">
<left>
<Border>
<ScrollPane horizontalScrollBarPolicy="fill_to_capacity">
- <TreeView wtkx:id="declaredEventsTreeView"
+ <TreeView bxml:id="declaredEventsTreeView"
checkmarksEnabled="true"
showMixedCheckmarkState="true"
selectMode="none">
@@ -37,7 +37,7 @@ limitations under the License.
<right>
<Border>
<ScrollPane horizontalScrollBarPolicy="fill_to_capacity">
- <TableView wtkx:id="firedEventsTableView" selectMode="none">
+ <TableView bxml:id="firedEventsTableView" selectMode="none">
<columns>
<TableView.Column name="interface" width="175"
headerData="%interface"/>
Modified: pivot/trunk/tools/src/org/apache/pivot/tools/xml/XMLViewer.java
URL: http://svn.apache.org/viewvc/pivot/trunk/tools/src/org/apache/pivot/tools/xml/XMLViewer.java?rev=955094&r1=955093&r2=955094&view=diff
==============================================================================
--- pivot/trunk/tools/src/org/apache/pivot/tools/xml/XMLViewer.java (original)
+++ pivot/trunk/tools/src/org/apache/pivot/tools/xml/XMLViewer.java Tue Jun 15 23:44:05 2010
@@ -70,11 +70,11 @@ public class XMLViewer implements Applic
@Override
public void startup(Display display, Map<String, String> properties)
throws Exception {
- BeanSerializer wtkxSerializer = new BeanSerializer();
- wtkxSerializer.put(APPLICATION_KEY, this);
+ BeanSerializer beanSerializer = new BeanSerializer();
+ beanSerializer.put(APPLICATION_KEY, this);
- window = (Window)wtkxSerializer.readObject(this, "xml_viewer.wtkx");
- wtkxSerializer.bind(this);
+ window = (Window)beanSerializer.readObject(this, "xml_viewer.bxml");
+ beanSerializer.bind(this);
Label prompt = new Label("Drag or paste XML here");
prompt.getStyles().put("horizontalAlignment", HorizontalAlignment.CENTER);
Copied: pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.bxml (from r954993, pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.wtkx)
URL: http://svn.apache.org/viewvc/pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.bxml?p2=pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.bxml&p1=pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.wtkx&r1=954993&r2=955094&rev=955094&view=diff
==============================================================================
--- pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.wtkx (original)
+++ pivot/trunk/tools/src/org/apache/pivot/tools/xml/xml_viewer.bxml Tue Jun 15 23:44:05 2010
@@ -17,10 +17,10 @@ limitations under the License.
-->
<Window maximized="true"
- xmlns:wtkx="http://pivot.apache.org/wtkx"
+ xmlns:bxml="http://pivot.apache.org/bxml"
xmlns:tools.xml="org.apache.pivot.tools.xml"
xmlns="org.apache.pivot.wtk">
- <wtkx:script src="xml_viewer.js"/>
+ <bxml:script src="xml_viewer.js"/>
<Border styles="{padding:4}">
<SplitPane splitRatio="0.6">
@@ -28,13 +28,13 @@ limitations under the License.
<Border styles="{color:10}">
<ScrollPane horizontalScrollBarPolicy="fill_to_capacity"
verticalScrollBarPolicy="fill_to_capacity">
- <TreeView wtkx:id="treeView" dropTarget="$treeViewDropTarget">
+ <TreeView bxml:id="treeView" dropTarget="$treeViewDropTarget">
<nodeRenderer>
<tools.xml:NodeRenderer/>
</nodeRenderer>
<componentKeyListeners>
- <wtkx:script>
+ <bxml:script>
<![CDATA[
importPackage(org.apache.pivot.wtk);
function keyPressed(component, keyCode, keyLocation) {
@@ -44,17 +44,17 @@ limitations under the License.
}
}
]]>
- </wtkx:script>
+ </bxml:script>
</componentKeyListeners>
<treeViewSelectionListeners>
- <wtkx:script>
+ <bxml:script>
<![CDATA[
function selectedPathsChanged(treeView, previousSelectedPaths) {
application.updateProperties();
}
]]>
- </wtkx:script>
+ </bxml:script>
</treeViewSelectionListeners>
</TreeView>
</ScrollPane>
@@ -62,13 +62,13 @@ limitations under the License.
</left>
<right>
- <CardPane wtkx:id="propertiesCardPane">
+ <CardPane bxml:id="propertiesCardPane">
<SplitPane orientation="vertical" splitRatio="0.2">
<top>
<Border styles="{color:10}">
<ScrollPane horizontalScrollBarPolicy="fill"
verticalScrollBarPolicy="fill_to_capacity">
- <TableView wtkx:id="namespacesTableView" selectMode="none">
+ <TableView bxml:id="namespacesTableView" selectMode="none">
<columns>
<TableView.Column name="prefix" width="1*" headerData="Prefix"/>
<TableView.Column name="uri" width="2*" headerData="URI"/>
@@ -87,7 +87,7 @@ limitations under the License.
<Border styles="{color:10}">
<ScrollPane horizontalScrollBarPolicy="fill"
verticalScrollBarPolicy="fill_to_capacity">
- <TableView wtkx:id="attributesTableView" selectMode="none">
+ <TableView bxml:id="attributesTableView" selectMode="none">
<columns>
<TableView.Column name="name" width="1*" headerData="Name"/>
<TableView.Column name="value" width="1*" headerData="Value"/>
@@ -106,7 +106,7 @@ limitations under the License.
<Border styles="{color:10}">
<ScrollPane horizontalScrollBarPolicy="fill_to_capacity"
verticalScrollBarPolicy="fill_to_capacity">
- <TextArea wtkx:id="textArea" editable="false" styles="{wrapText:false}"/>
+ <TextArea bxml:id="textArea" editable="false" styles="{wrapText:false}"/>
</ScrollPane>
</Border>
</CardPane>