Changeset 13764 in osm for applications


Ignore:
Timestamp:
2009-02-16T22:42:05+01:00 (15 years ago)
Author:
skela
Message:

Make tcxplugin compile, and fix the GPX export.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • applications/editors/josm/plugins/tcxplugin/src/org/openstreetmap/josm/io/TcxReader.java

    r13500 r13764  
    103103        WayPoint waypt = new WayPoint(new LatLon(p.getLatitudeDegrees(),
    104104                                                 p.getLongitudeDegrees()));
    105         // If WayPoint handled elevation data, we could get it from
    106         // tp.getAltitudeMeters().
     105        Double altitudeMeters = tp.getAltitudeMeters();
     106        if (altitudeMeters != null) {
     107            waypt.attr.put("ele", altitudeMeters.toString());
     108        }
    107109
    108110        XMLGregorianCalendar time = tp.getTime();
    109111
    110112        if (time != null) {
     113            waypt.attr.put("time", time.toString());
    111114            waypt.time = .001 * time.toGregorianCalendar().getTimeInMillis();
    112115        }
     
    141144                                                waypt.attr.put("name",
    142145                                                               startTime
    143                                                                .toString());
     146                                                               .toString());
    144147                                                startTime = null;
    145148                                            }
Note: See TracChangeset for help on using the changeset viewer.