Revision: 6126
          http://sourceforge.net/p/jump-pilot/code/6126
Author:   edso
Date:     2019-02-17 12:56:58 +0000 (Sun, 17 Feb 2019)
Log Message:
-----------
also read <placemark>s if no <Folder> exists

Modified Paths:
--------------
    plug-ins/KmlDriver/trunk/ChangeLog
    plug-ins/KmlDriver/trunk/src/com/isa/jump/plugin/KMLReader.java

Modified: plug-ins/KmlDriver/trunk/ChangeLog
===================================================================
--- plug-ins/KmlDriver/trunk/ChangeLog  2019-02-10 13:09:02 UTC (rev 6125)
+++ plug-ins/KmlDriver/trunk/ChangeLog  2019-02-17 12:56:58 UTC (rev 6126)
@@ -1,5 +1,5 @@
 History
-
+0.2.5 (2019-02-17) also read <placemark> if no <Folder> exists
 0.2.4 (2015-04-05) reenable loading of kmz files, reformatting removing tabs
                    move version variable to build.xml header
                    move changes into this dedicated file

Modified: plug-ins/KmlDriver/trunk/src/com/isa/jump/plugin/KMLReader.java
===================================================================
--- plug-ins/KmlDriver/trunk/src/com/isa/jump/plugin/KMLReader.java     
2019-02-10 13:09:02 UTC (rev 6125)
+++ plug-ins/KmlDriver/trunk/src/com/isa/jump/plugin/KMLReader.java     
2019-02-17 12:56:58 UTC (rev 6126)
@@ -345,6 +345,7 @@
    */
   public void endElement(String uri, String name, String qName)
       throws SAXException {
+    //System.out.println("endElement: "+qName);
     try {
       int index;
 
@@ -568,7 +569,7 @@
   public void startElement(String uri, String name, String qName,
       Attributes atts) throws SAXException {
     try {
-      // System.out.println("Start element: " + qName);
+      //System.out.println("Start element: " + qName+"/"+STATE);
       tagBody = new StringBuffer();
       lastStartTag_uri = uri;
       lastStartTag_name = name;
@@ -582,16 +583,16 @@
       if ((STATE == STATE_WAIT_COLLECTION_TAG)
           && (qName.compareToIgnoreCase(collectionElement) == 0)) {
         // found the collection tag
-        // System.out.println("found collection");
+        //System.out.println("found collection");
         STATE = STATE_WAIT_FEATURE_TAG;
 
         return;
       }
 
-      if ((STATE == STATE_WAIT_FEATURE_TAG)
+      if ( ( STATE == STATE_WAIT_FEATURE_TAG  || STATE == 
STATE_WAIT_COLLECTION_TAG )
           && (qName.compareToIgnoreCase(featureElement) == 0)) {
         // found the feature tag
-        // System.out.println("found feature");
+        //System.out.println("found feature");
         currentFeature = new BasicFeature(fcmd);
         STATE = STATE_PARSE_GEOM_SIMPLE; // STATE_FOUND_FEATURE_TAG;
         recursivegeometry = new ArrayList();



_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to