Use VectorCollection class for data binding on Vectors.
authorRichard Fairhurst <richard@systemeD.net>
Sat, 1 Oct 2011 07:46:14 +0000 (08:46 +0100)
committerRichard Fairhurst <richard@systemeD.net>
Sat, 1 Oct 2011 07:46:14 +0000 (08:46 +0100)
Fixes issue with 'My tracks' display not working.

lib/vector-collection-1.1.0-Final.swc [new file with mode: 0644]
net/systemeD/potlatch2/mygpx/MyGpxDialog.mxml

diff --git a/lib/vector-collection-1.1.0-Final.swc b/lib/vector-collection-1.1.0-Final.swc
new file mode 100644 (file)
index 0000000..41817f4
Binary files /dev/null and b/lib/vector-collection-1.1.0-Final.swc differ
index ec57b37..019ab46 100644 (file)
@@ -3,7 +3,7 @@
         xmlns:fx="http://ns.adobe.com/mxml/2009"
         xmlns:mx="library://ns.adobe.com/flex/mx"
         layout="vertical" showCloseButton="true"
-        horizontalAlign="center" title="MyGpx Files"
+        horizontalAlign="center" title="My tracks"
         width="600" height="400"
         verticalGap="0">
   <fx:Script><![CDATA[
@@ -19,6 +19,7 @@
     import net.systemeD.potlatch2.utils.Importer;
     import net.systemeD.potlatch2.utils.GpxImporter;
     import mx.controls.Alert;
+    import com.bealearts.collection.VectorCollection;
 
     private var map:Map;
     private var conn:Connection;
@@ -52,8 +53,8 @@
     }
 
     [Bindable(event="traces_loaded")]
-    private function get traces():Vector.<Trace> {
-        return conn.getTraces();
+    private function get traces():VectorCollection {
+               return new VectorCollection(conn.getTraces());
     }
 
     public function loadFile(t:Trace):void {